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: glibc only with optimization?


On Friday 07 September 2007, Carlos O'Donell wrote:
> On 9/7/07, Simon Peter <dn.tlp@gmx.net> wrote:
> > > > > error: #error "glibc cannot be compiled without optimization"
> > > >
> > > > Why is that?
> > >
> > > Refer to list archives from April 19.
> >
> > Thanks for the pointer, but the information given there is still
> > insufficient to me. The last mail posted in the thread from April 19
> > states that inlining is necessary. Now why is that?
>
> In the early startup of the dynamic loader (_dl_start), before
> relocation of the PLT, you cannot make function calls. You must inline
> the functions you will use during early startup, or call compiler
> builtins (__builtin_*).
>
> Without optimizations enabled gcc will not inline functions. The early
> startup of the dynamic loader will make function calls via an
> unrelocated PLT and crash.

which could be addressed by declaring them "static inline 
__attribute__((always_inline))", but i get the feeling drepper would 
derisively say no to such a thing
-mike

Attachment: signature.asc
Description: This is a digitally signed message part.


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