home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #26 / NN_1992_26.iso / spool / comp / os / msdos / programm / 10487 < prev    next >
Encoding:
Text File  |  1992-11-10  |  1.4 KB  |  37 lines

  1. Newsgroups: comp.os.msdos.programmer
  2. Path: sparky!uunet!charon.amdahl.com!pacbell.com!decwrl!borland.com!news!cfortier
  3. From: cfortier@genghis.news (Chris Fortier)
  4. Subject: COMPILATION SPEED
  5. Message-ID: <CFORTIER.92Nov10130727@genghis.news>
  6. Sender: news@borland.com (News Admin)
  7. Organization: Borland International, Inc.
  8. Date: Tue, 10 Nov 1992 21:07:27 GMT
  9. Lines: 26
  10.  
  11.  
  12. THE difference between Borland Pascal and Borland C++ compilation speed
  13. is attributable to header files.  Period.
  14.  
  15. A Borland Pascal program simply inserts the statement "uses xx.tpu", whereby
  16. the compiler simply loads the binary image into memory.
  17.  
  18. Borland C++ programs use "#include xx.h", whereby the compiler must PARSE the
  19. source text.  If there are many header files, the loss of speed can be 
  20. dramatic.
  21.  
  22. There is a way in C++ to get much better compilation speeds, precompiled
  23. headers.  These function in the same way as a Borland Pascal uses statement,
  24. allowing compilation times to be much faster, albeit, probably still a little
  25. slower than Borland Pascal.
  26.  
  27. Another thing to remember with Borland Pascal, there is no separate link step.
  28. The compiler does everything in one executable.  The link step in Borland C++
  29. is separate, thus there is time spent in unloading the compiler and loading 
  30. the linker in memory.  Both ways have their advantages and disadvantages.
  31.  
  32. Chris Fortier
  33. Borland C++ Run Time Library QA
  34.  
  35. cfortier@borland.com
  36.  
  37.