home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #18 / NN_1992_18.iso / spool / comp / os / linux / 8224 < prev    next >
Encoding:
Internet Message Format  |  1992-08-14  |  1.8 KB

  1. Path: sparky!uunet!gatech!rpi!crdgw1!rdsunx.crd.ge.com!ariel!davidsen
  2. From: davidsen@ariel.crd.GE.COM (william E Davidsen)
  3. Newsgroups: comp.os.linux
  4. Subject: shared libs - can everyone be happy with this?
  5. Message-ID: <1992Aug14.145754.29366@crd.ge.com>
  6. Date: 14 Aug 92 14:57:54 GMT
  7. Sender: usenet@crd.ge.com (Required for NNTP)
  8. Reply-To: davidsen@crd.ge.com (bill davidsen)
  9. Organization: GE Corporate R&D Center, Schenectady NY
  10. Lines: 29
  11. Nntp-Posting-Host: ariel.crd.ge.com
  12.  
  13.  
  14.   I have an idea which I think might be a useful compromise between the
  15. "never recompile" and the "last ounce of performance" approaches.
  16. Unfortunately I can't find enough info on the GNU ld to know if it is
  17. feasible.
  18.  
  19.   What I propose is to have a module at the start of the shared library
  20. which is the jump table module. When the module is used it provides defs
  21. for each of the library functions by use of the jump table. The
  22. jumptbl() module would always be physically first in the library, so it
  23. would be "in the same place." So far this sounds like the original idea,
  24. right?
  25.  
  26.   If you didn't want to use the jump tables, you don't load the module
  27. and you get linked to the real routines directly in memory in the slib.
  28. The advantage of this is that you get all the benefits of the current
  29. slib implementation in terms of performance.
  30.  
  31.   This would allow
  32.   a. static link - runs anywhere
  33.   b. dynamic link - must relink for new slibs, but faster than -
  34.   c. jtablink - no need to relink for new libs, slightly slower than (b)
  35.  
  36. That would let the user decide what combination of size, portability and
  37. performance is best for each program, and that should make everyone happy.
  38.  
  39. -- 
  40. bill davidsen, GE Corp. R&D Center; Box 8; Schenectady NY 12345
  41.     I admit that when I was in school I wrote COBOL. But I didn't compile.
  42.