Hi Rod, Is the value that is held in the variable _GLOBAL_OFFSET_TABLE_ the offset of the GOT from the File base or it is the offset value from the current location of the PC where this variable is referenced ? Please clarify this doubt.
Regards, Rajesh -----Original Message----- From: Rod Evans [mailto:rod.ev...@sun.com] Sent: Friday, March 30, 2007 1:56 AM To: Rajesh Paul Cc: tools-linking at opensolaris.org Subject: Re: [tools-linking] Re: Re: DT_SUNW_RTLDINF Dynamic Tag Rajesh Paul wrote: > There is another filter function '_ld_libc' in libc.so used to load some more > interfaces. It is called from libc_init(). It is also called from setlocale to inform ld.so.1 of a locale change. > What is the purpose of it being defined as a filter function in libc.so ? Any external reference to an implementation within ld.so.1 is directed through a filter. This used to be libdl.so.1, however, we were able to fold libdl into libc when individual symbol filters were created. > It could have been instead an external interface defined in ld.so. You can't link against ld.so.1 directly, you can only reference its interfaces through filters. ld.so.1 has many external interfaces that allow ld.so.1 to communicate with its own dependencies, however we don't want users arbitrarily calling any ld.so.1 interface. Filters provide the "public" interface to ld.so.1. > Does that mean other user land dynamic executables and shared objects can > also invoke '_ld_libc' (libc.so being the supplier at link-edit time) ? In theory, yes. However, only libc.so.1 references this interface - hopefully, libc knows what it's doing :-) -- Rod.