This is the mail archive of the 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: Mathinlines and GCC

On 05/02/2012 09:29 PM, Joseph S. Myers wrote:
On Wed, 2 May 2012, Andreas Jaeger wrote:

So, for me the questions is: Shouldn't we cleanup the mathinline headers
and remove whatever functions a GCC of our choice (I would use the last
released one - 4.7) can optimize? Most inlines are only for GCC and if
GCC knows about it, it can do a better job.

Normally we condition inlines so that they are disabled for the particular GCC versions that can do the optimization themselves. (But instead of adding new ones we should certainly look to add GCC optimizations instead in most cases.)

I don't see any of this in the x86-64 specific version. On the other hand I see it in the i386 specific header.

One more question: why do we explicitely call the builtin via an inline instead of letting gcc do this?

here's an example from the i386 header:
#if __GNUC_PREREQ (3, 4)
__inline_mathcodeNP2_ (long double, __atan2l, __y, __x,
		       return __builtin_atan2l (__y, __x))

 Andreas Jaeger aj@{,} Twitter/Identica: jaegerandi
  SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
   GF: Jeff Hawn,Jennifer Guild,Felix Imendörffer,HRB16746 (AG Nürnberg)
    GPG fingerprint = 93A3 365E CE47 B889 DF7F  FED1 389A 563C C272 A126

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