home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #30 / NN_1992_30.iso / spool / comp / compiler / 2019 < prev    next >
Encoding:
Text File  |  1992-12-12  |  2.3 KB  |  53 lines

  1. Newsgroups: comp.compilers
  2. Path: sparky!uunet!think.com!spdcc!iecc!compilers-sender
  3. From: chased@rbbb.Eng.Sun.COM (David Chase)
  4. Subject: Re: static estimation of conditional branches?
  5. Reply-To: chased@rbbb.Eng.Sun.COM (David Chase)
  6. Organization: SunPro
  7. Date: Sat, 12 Dec 1992 20:15:16 GMT
  8. Approved: compilers@iecc.cambridge.ma.us
  9. Message-ID: <92-12-051@comp.compilers>
  10. Keywords: optimize
  11. References: <92-12-029@comp.compilers> <92-12-049@comp.compilers>
  12. Sender: compilers-sender@iecc.cambridge.ma.us
  13. Lines: 38
  14.  
  15. Henry Spencer <henry@zoo.toronto.edu> writes:
  16. > The other problem that occurs with such facilities is that programmer
  17. > intuition is notoriously unreliable about such things.
  18.  
  19. idacrd!desj@uunet.UU.NET (David desJardins) writes:
  20. >I don't understand this statement in this context in this context.  I know
  21. >it's fashionable in this group to claim that compilers are supergeniuses
  22. >and humans are idiots.
  23.  
  24. Compilers are super-patient and humans are not.
  25.  
  26. >But any programmer who is making a serious effort to write high-
  27. >performance code must know ...
  28.  
  29. You've got to be careful about confusing common-case and best-case.  If
  30. 80% of the programmers either don't bother or don't know 80% of the time,
  31. then I'd call that "notoriously unreliable".  That still leaves plenty of
  32. room for many people to occasionally know exactly what is happening.
  33. However, those people are a distinct minority, and catering to their needs
  34. is not likely to bring as large a reward as catering to the needs of the
  35. common case.  (I.e., consider economics.)
  36.  
  37. >Of course, I too endorse the feedback of profiler information as a more
  38. >convenient (to the user) way to achieve similar results.
  39.  
  40. Because it is more convenient, it is used by more people, and hence has a
  41. bigger reward than special-case frequency hints.  Profiling feedback is
  42. also useful because it does not require source code changes -- if you
  43. discover that your training inputs are not typical, you merely get some
  44. better ones, train, and recompile.  Source code changes are much more
  45. costly because they involve more human interaction and can include the
  46. possibility of introducing errors (even if only a typo).
  47.  
  48. David Chase
  49. Sun
  50. -- 
  51. Send compilers articles to compilers@iecc.cambridge.ma.us or
  52. {ima | spdcc | world}!iecc!compilers.  Meta-mail to compilers-request.
  53.