home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #27 / NN_1992_27.iso / spool / comp / arch / 10956 < prev    next >
Encoding:
Internet Message Format  |  1992-11-20  |  3.1 KB

  1. Xref: sparky comp.arch:10956 comp.lang.misc:3810
  2. Path: sparky!uunet!olivea!charnel!sifon!thunder.mcrcim.mcgill.edu!snorkelwacker.mit.edu!ai-lab!life.ai.mit.edu!tmb
  3. From: tmb@arolla.idiap.ch (Thomas M. Breuel)
  4. Newsgroups: comp.arch,comp.lang.misc
  5. Subject: Re: how to advocate new software/hardware features (Re: Hardware Support for Numeric Algorithms)
  6. Message-ID: <TMB.92Nov20133736@arolla.idiap.ch>
  7. Date: 20 Nov 92 21:37:36 GMT
  8. References: <TMB.92Nov17223828@arolla.idiap.ch>
  9.     <1992Nov19.105510.563@uklirb.informatik.uni-kl.de>
  10. Reply-To: tmb@idiap.ch
  11. Organization: IDIAP (Institut Dalle Molle d'Intelligence Artificielle
  12.     Perceptive)
  13. Lines: 50
  14. NNTP-Posting-Host: arolla.idiap.ch
  15. In-reply-to: kirchner@uklira.informatik.uni-kl.de's message of Thu, 19 Nov 1992 10:55:10 GMT
  16.  
  17. In article <1992Nov19.105510.563@uklirb.informatik.uni-kl.de> kirchner@uklira.informatik.uni-kl.de (Reinhard Kirchner) writes:
  18.  
  19.    From article <TMB.92Nov17223828@arolla.idiap.ch>, by tmb@arolla.idiap.ch (Thomas M. Breuel):
  20.    > On the other hand, please do spare the rest of us
  21.    > complex syntactic extensions ("!<>", "?)~", etc.) for all those
  22.    > special purpose features.
  23.  
  24.    So Thomas wants us to write big numerical software in "assembler", or
  25.    what else are these library calls ?
  26.  
  27. One of the main differences between assembler and high-level languages
  28. is the ability to compose functions, or, in different words, not to
  29. have to worry about where to store intermediate results. Whether a
  30. language has infix operators or not is a trivial feature in
  31. comparison.
  32.  
  33. In fact, there are assembly language with infix operators, while a lot
  34. of numerical software has been written in languages (Lisp/Scheme)
  35. without any infix operators. Writing numerical software in Lisp/Scheme
  36. is certainly a whole lot more convenient than writing it in assembly
  37. language or even FORTRAN or C (both of which do have infix syntax).
  38.  
  39.    The syntax extensions for rounding control are quite simple, a > or < behind
  40.    the op, e.g. +>, -<, *< etc.
  41.  
  42. You are missing the point. In my experience, new operators make
  43. program analysis and maintenance harder. A rarely used feature like
  44. "x+>y" is much easier to read and recognized if written as
  45. "add_rounding_down(x,y)" than as "+>" (in fact, what is "+>" actually
  46. supposed to mean?). Another problem is that "+>" (whatever it may
  47. mean) is not available on a lot of hardware, and
  48. implementation-specific features should probably always go into
  49. libraries.
  50.  
  51. I don't need per-instruction control over rounding mode frequently,
  52. and I think that is true for most other users. Hence, I would oppose
  53. the addition of special syntax for it to any language I'm using. You
  54. are, of course, welcome to disagree.
  55.  
  56.    The problem is much more difficult with operations which give two results,
  57.    like additions generating a carry. But these may really be hidden in
  58.    some higher operations.
  59.  
  60. In my opinion, returning multiple values is a feature that is useful
  61. enough to enough people to warrant better language support. Note that
  62. in FORTRAN, this is altogether impossible, while in C, you can
  63. "simulate" it using structures. SML and CommonLisp support it
  64. directly.
  65.  
  66.                 Thomas.
  67.