Re: Enormous C-ISAM binaries
Posted in 1997
On 8 Oct 1997, Craig Macbride wrote: > In case anyone is interested, here are some details on what happens to > one little program when compiled with C-ISAM v7. I have compiled it using > stubs to prevent the C-ISAM lib loading, then with the C-ISAM lib as usual, > in both ELF and COFF form. These are the sizes for on-disk binary and > 'size' command output respectively: > > ELF (with stubs): 16944, 14352 > ELF (with CISAM): 376260, 311486 > > COFF (with stubs): 63363, 43432 > COFF (with CISAM): 540204, 398672 > > Back in the days of C-ISAM v4, I could use the same C-ISAM functions and > have it add something less than 100k to the COFF binary size, if I remember > correctly. The latest version adds 480k, which is quite enormous. I wish I > still had access to the old v4 code, so that I could see whether the speed > of the new C-ISAM is significantly different. I think a fairly large portion of the problem is the GLS library which is embedded in the C-ISAM library from 7.20 onwards. I've just extracted the object files from the 7.24.UC1 C-ISAM library on Solaris 2.5.1 (Sun Sparc 20). There are 28 GLS files (cinitgls.o plus the names gl*.o -- I omitted islamic.o and hebrew.o which are also GLS files, I think). Running size(1) on these and summing yields 313574 bytes. The difference between the size(1) report for your stubbed and unstubbed programs is similar to the size of the GLS library. I wonder why there isn't a shared C-ISAM library? And why it doesn't use the shared GLS library that is provided with ESQL/C? Maybe some customers should request these changes. Yours, Jonathan Leffler (johnl@informix.com) #include <witticism.h> FYI: Raw size data on Sparc (C-ISAM 7.24.UC1): cinitgls.o: 18568 + 1373 + 0 = 19941 decconv.o: 13475 + 0 + 0 = 13475 decmath.o: 2901 + 0 + 0 = 2901 gcvio.o: 7399 + 0 + 0 = 7399 gcvsrv.o: 3331 + 0 + 0 = 3331 gdecinit.o: 5658 + 38 + 0 = 5696 geninit.o: 1209 + 396 + 0 = 1605 genisam.o: 1221 + 34 + 0 = 1255 gerrno.o: 196 + 82 + 0 = 278 glscoll.o: 12917 + 0 + 0 = 12917 glsctype.o: 5031 + 94 + 0 = 5125 glscvlib.o: 10282 + 1044 + 0 = 11326 glsext.o: 138 + 0 + 0 = 138 glsextfn.o: 4086 + 4 + 0 = 4090 glsextsa.o: 1949 + 0 + 0 = 1949 glsfmt.o: 20063 + 33 + 0 = 20096 glsinfo.o: 2704 + 26 + 0 = 2730 glsio.o: 4835 + 21 + 0 = 4856 glslen.o: 2030 + 0 + 0 = 2030 glslibn.o: 8702 + 0 + 0 = 8702 glslistl.o: 766 + 0 + 0 = 766 glsmb.o: 2147 + 0 + 0 = 2147 glsmbwc.o: 2987 + 0 + 0 = 2987 glsmnlib.o: 19084 + 3 + 0 = 19087 glsmultl.o: 13020 + 118 + 0 = 13138 glsoflib.o: 449 + 0 + 0 = 449 glssetlc.o: 41056 + 6108 + 0 = 47164 glsspec.o: 10285 + 2667 + 0 = 12952 glsstr.o: 28583 + 77 + 0 = 28660 glssymsl.o: 11456 + 430 + 0 = 11886 glsthcol.o: 7783 + 416 + 0 = 8199 glstmcvt.o: 1357 + 244 + 0 = 1601 glstmlib.o: 55989 + 114 + 0 = 56103 glstree.o: 4164 + 0 + 0 = 4164 glsutill.o: 9870 + 407 + 4 = 10281 glswin.o: 90 + 0 + 0 = 90 gnmlist.o: 971 + 0 + 0 = 971 gregor.o: 774 + 48 + 0 = 822 gtoerrno.o: 507 + 0 + 0 = 507 gvalid.o: 2033 + 199 + 0 = 2232 hash.o: 2291 + 37 + 0 = 2328 hebrew.o: 2726 + 0 + 0 = 2726 isaudit.o: 3721 + 0 + 0 = 3721 isbtree.o: 3640 + 0 + 0 = 3640 isbuf.o: 4630 + 113 + 0 = 4743 isbuild.o: 9688 + 4 + 0 = 9692 isclustr.o: 3681 + 22 + 0 = 3703 iscoll.o: 1135 + 540 + 0 = 1675 isdatax.o: 3858 + 32 + 0 = 3890 isdef.o: 993 + 124 + 0 = 1117 iserrmsg.o: 1039 + 2153 + 0 = 3192 isitem.o: 3659 + 0 + 0 = 3659 iskey.o: 4473 + 20 + 0 = 4493 islamic.o: 2460 + 120 + 0 = 2580 islock.o: 5164 + 0 + 36 = 5200 isnode.o: 4675 + 2 + 0 = 4677 isopen.o: 15792 + 30 + 72 = 15894 isread.o: 5235 + 0 + 4 = 5239 isrecvr.o: 14943 + 715 + 0 = 15658 isrprim.o: 10808 + 16 + 0 = 10824 issupp.o: 8239 + 52 + 0 = 8291 istrans.o: 14508 + 85 + 0 = 14593 iswrite.o: 11704 + 0 + 0 = 11704 osasmb.o: 635 + 0 + 0 = 635 osctype.o: 1540 + 787 + 0 = 2327 osdefenv.o: 4763 + 2905 + 200 = 7868 osenv.o: 8301 + 501 + 0 = 8802 osfutil.o: 4591 + 69 + 0 = 4660 osinit.o: 1330 + 0 + 0 = 1330 osnls.o: 5938 + 70 + 0 = 6008 ospasswd.o: 3583 + 6 + 0 = 3589 osqlidbg.o: 3447 + 307 + 0 = 3754 osstore.o: 1645 + 8 + 0 = 1653 osutil.o: 3378 + 0 + 0 = 3378 rstod.o: 2011 + 0 + 0 = 2011 rstoi.o: 587 + 0 + 0 = 587 sort.o: 11858 + 50 + 16 = 11924