Thread: Size of exe file

  1. #1
    Registered User
    Join Date
    Nov 2002

    Size of exe file

    I am working on Borland C++ 4.0 version compiler and Win NT system.

    If I add any standard library function very first time to my program, size of the exe file increases significantly, whereas, adding the same library function next time will increase the file size by few bytes.

    For example, Using sscanf first time, increased the file size by about 2000 bytes. But adding the same library function next time, increased it by only 20 bytes.

    Can anybody explain me this?

    Is this true with my own written function?( in Same file and not from Library)

    As per my understanding, library functions are statically linked and not dynamically.


  2. #2
    ATH0 quzah's Avatar
    Join Date
    Oct 2001
    The first time you use a functon in a library, it includes the header and your line of code. Additional uses just add your extra function call, thus, you only get a few more bytes to your executable.

    Hope is the first step on the road to disappointment.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Need Help Fixing My C Program. Deals with File I/O
    By Matus in forum C Programming
    Replies: 7
    Last Post: 04-29-2008, 07:51 PM
  2. Basic text file encoder
    By Abda92 in forum C Programming
    Replies: 15
    Last Post: 05-22-2007, 01:19 PM
  3. Replies: 11
    Last Post: 03-25-2003, 05:13 PM
  4. System
    By drdroid in forum C++ Programming
    Replies: 3
    Last Post: 06-28-2002, 10:12 PM