From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: fc89c,97188312486d4578 X-Google-Attributes: gidfc89c,public X-Google-Thread: 109fba,baaf5f793d03d420 X-Google-Attributes: gid109fba,public X-Google-Thread: 103376,97188312486d4578 X-Google-Attributes: gid103376,public X-Google-Thread: 1014db,6154de2e240de72a X-Google-Attributes: gid1014db,public X-Google-Thread: 10db24,4cf070091283b555 X-Google-Attributes: gid10db24,public From: Dan.Pop@cern.ch (Dan Pop) Subject: Re: What's the best language to learn? [was Re: Should I learn C or Pascal?] Date: 1996/08/17 Message-ID: #1/1 X-Deja-AN: 174801877 sender: news@news.cern.ch (USENET News System) x-nntp-posting-host: ues5.cern.ch references: <4u7hi6$s2b@nntp.seflin.lib.fl.us> <4uo74j$95p@ns.broadvision.com> <01bb8950$2c8dcc60$87ee6fce@timpent.airshields.com> <4ut8h3$2an@ccshst05.uoguelph.ca> <01bb8c6d$c62d44c0$87ee6fce@timpent.airshields.com> organization: CERN European Lab for Particle Physics newsgroups: comp.edu,comp.lang.ada,comp.lang.c,comp.lang.c++,comp.unix.programmer Date: 1996-08-17T00:00:00+00:00 List-Id: In <01bb8c6d$c62d44c0$87ee6fce@timpent.airshields.com> "Tim Behrendsen" writes: >It's extremely rare that hand coded assembly is slower than >compiler output. Compilers are *extremely* stupid; anyone who >thinks otherwise has either 1) not coded in assembly, and 2) not >viewed the assembly output from compilers. They are certainly >less stupid than they used to be, but to imagine that on the >average they beat even the average human assembly programmer is >just nonsense. Try to test your assertions with a nontrivial piece of code on a P6 or any modern RISC processor. The human mind is very badly adapted to the task of generating optimal code for these architectures, while compilers could be "trained" for this job a lot easier and more successfully. There are "pathological" cases, when an algorithm cannot be suitably implemented in a HLL but can be implemented in only a few assembly lines (this is especially true for some data conversion or multiple precision arithmetic algorithms), but these are the exceptions, not the rule. The days of Z80 and i8086, when a relatively inexperienced assembly programmer could beat the best compiler of the day single handed are long gone. Dan -- Dan Pop CERN, CN Division Email: Dan.Pop@cern.ch Mail: CERN - PPE, Bat. 31 R-004, CH-1211 Geneve 23, Switzerland