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 6/6] Compile sched_getaffinity.c with -fno-builtin-memset


On Fri, 14 Aug 2015, H.J. Lu wrote:

> > We're declaring (essentially, though a load of macros):
> >
> > extern __typeof (memset) memset __asm__ ("__GI_memset") __attribute__ ((visibility ("hidden")));
> >
> > GCC is using the __asm__ information to compile calls to __builtin_memset
> > to use the assembler name __GI_memset - that is, in that regard our
> > declaration is being taken as applying to the libcall.  If it's not also
> > using the visibility information to know that those are calls within the
> > library and don't need to set up %ebx, that's a clear inconsistency; all
> > pieces of information from an explicit declaration of a built-in function
> > should be treated the same unless there is a clear reason not to do so.
> >
> 
> Should I open a GCC bug?

If you wish (and have verified that %ebx is being unnecessarily set up).  
It's a missed optimization rather than an actual bug.

-- 
Joseph S. Myers
joseph@codesourcery.com


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