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

  1. Newsgroups: comp.os.msdos.programmer
  2. Path: sparky!uunet!utcsri!torn!news.ccs.queensu.ca!mast.queensu.ca!dmurdoch
  3. From: dmurdoch@mast.queensu.ca (Duncan Murdoch)
  4. Subject: Re: COMPILING SPEED
  5. Message-ID: <dmurdoch.257.721088574@mast.queensu.ca>
  6. Lines: 25
  7. Sender: news@knot.ccs.queensu.ca (Netnews control)
  8. Organization: Queen's University
  9. References: <BwB79x.1sB@ecf.toronto.edu> <1992Nov6.102017.17897@sequent.com> <dmurdoch.253.721061938@mast.queensu.ca>
  10. Distribution: na
  11. Date: Fri, 6 Nov 1992 22:22:54 GMT
  12.  
  13. In article <dmurdoch.253.721061938@mast.queensu.ca> dmurdoch@mast.queensu.ca (Duncan Murdoch) writes:
  14. >Why do people accept such slow compile times?  Turbo Pascal demonstrates 
  15. >that fast compiler technology exists.  Is C++ five times harder to compile 
  16. >than TP?
  17.  
  18. Someone from Borland pointed out to me that C++ is indeed a much 
  19. more complex language than TP, but the main thing is that the C++ language 
  20. is not under Borland's control.  Borland can pick and choose features for 
  21. Turbo Pascal with an eye to compiler efficiency, while someone else chooses 
  22. what goes into C++.  Another consideration that comes from the size of C++ 
  23. is that it's hard to fit the compiler in real mode memory; DPMI slows it 
  24. down.  I'd tend to discount this; TP for Windows runs in protected 
  25. mode nearly as fast as TP for DOS runs.  Finally, C++ includes more 
  26. optimizations than TP - but even with those turned off, it runs much slower.
  27.  
  28. One consequence of this that wasn't mentioned, but which is probably really 
  29. the reason for TP's superior speed, is that the TP compiler is written in 
  30. hand-optimized assembler.  Because C++ is so big, and because it's liable to 
  31. change under someone else's control, it has to be written in a high level 
  32. language.  (I'd assume C, with low level service routines in assembler; can 
  33. anyone confirm or deny that?)  
  34.  
  35.  
  36. Duncan Murdoch
  37. dmurdoch@mast.queensu.ca
  38.