This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Add inline bsearch expansion


On Sat, Jan 05, 2013 at 01:51:30PM +0100, OndÅej BÃlka wrote:
> I looked into qsort/bsearch functions. Here I
> added inline version of bsearch.
> 
> It saves multiplications instructions as size is 
> most of time known in advance.
> When compiled with gcc-4.7.1 and icc 12.1.4 with -O2
> it can inline ccmp functions from example below.
> gcc-4.5.3 does not inline ccmp.

I don't comment on whether it is a good idea or not etc.,
just nits that you should guard it with
#ifdef __USE_EXTERN_INLINES
and use
__extern_inline
instead of extern inline.

	Jakub


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]