> Date: Wed, 14 May 2008 12:43:07 +0200
> From: Joerg.Schilling at fokus.fraunhofer.de (Joerg Schilling)
> Subject: Re: PSARC/2008/309 - expunge synonyms.h
> To: Roger.Faulkner at sun.com, psarc-ext at sac.sfbay.sun.com
> Cc: rod.evans at sun.com, darrin.johnson at sun.com, bart.smaalders at sun.com
> 
> "Roger A. Faulkner" <Roger.Faulkner at sun.com> wrote:
> 
> ....
> 
> > ==============================================================
> > The better solution
> >
> > So much for history.  Now for today's situation.
> >
> > The change for this bug report was recently integrated
> > into /ws/onnv-gate:
> >
> > 4947191 OSNet should use direct bindings
> >
> > This causes all OS/NET libraries, including libc, to be built
> > using direct binding (-B direct).  As a result, all symbols
> > referenced by a library are bound either to the definition
> > within itself or to the definition within its direct dependencies.
> 
> From my understanding, this would prevent applications to replace "malloc"
> that are based on brk(2)/sbrk(2).
> 
> libc currently binds to the malloc()/.... functions from the application.
> Binding to libc internal functions is currently only done for those functions
> that need to be the way libc defines them.
> 
> Using a "direct" binding to all libc functions looks to me like ignoring 
> linking rules. 
> 
> if you are sure that this change would not cause any problems please explain 
in 
> more details.
> 
> J?rg

The '-B direct' change for all system libraries has already been done.
It is independent of (but required by) my proposed synonyms.h elimination.
As my mail went on to say:

: The application calls its instance and the library calls its
: instance, even though both instances have the same name.
: (Excepting, of course, symbols in the malloc() family and
: other symbols explicitly defined to be interposable symbols
: by default.  These have all been marked NODIRECT in the
: appropriate mapfiles.  [The devil is in the details.])

The malloc family is marked NODIRECT in libc's mapfiles:

        calloc = NODIRECT;
        cfree = NODIRECT;
        free = NODIRECT;
        malloc = NODIRECT;
        memalign = NODIRECT;
        realloc = NODIRECT;
        valloc = NODIRECT;

Roger


Reply via email to