This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC 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: GCC viciously beaten by ICC in trig test!


On Mon, Mar 15, 2004 at 10:13:13AM -0800, Joe Buck wrote:
> On Mon, Mar 15, 2004 at 07:11:04AM +0100, Jakub Jelinek wrote:
> > Well, the inlines shouldn't be removed, but guarded with
> > # if !__GNUC_PREREQ (MAJOR,MINOR)
> > ...
> > # endif
> > where MAJOR, MINOR is the first __GNUC__ and __GNUC_MINOR__ of GCC which
> > can handle all cases the same or better than the glibc inline.
> 
> Is the proper requirement "all cases"?  What if the glibc inline is
> sometimes better, but sometimes far worse?

Ok, all cases is not necessary, but good judgement needs to be applied.
I've tried to look at a few inlines today, e.g. signbit in GCC is as good
as glibc builtin, which means __builtin_signbit should be used,
but already on IA-32 __builtin_signbitl is worse.
Although GCC 3.5 has really many math builtins, most of them do nothing
and thus are usually worse than what GLIBC provides (tried e.g. exp, tan).

	Jakub


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