TIP: Click on subject to list as thread! ANSI
echo: os2prog
to: Murray Lesser
from: Thomas Seeling
date: 1997-01-22 21:45:14
subject: writing REXX DLL`s

Hallo, Murray!

*** Am 20. Januar 1997 um 07:51 schrieb Murray Lesser an Thomas Seeling:

 ML>     I learned many years ago that, for best performance, one should
 ML> always put the most likely case first (even if it is the negative case).

This sounds reasonable (I learnt it, too), but modern optimizers turn e.g.
a switch into an array of function (or jump address) pointers, and some
even optimize if/else if/else if/.../else cascades this way.

In general I agree: write it readable, not "human optimized". let
the compiler do its best (there have been studies that the straight-forward
approach when coding an algorithm yields the best results after compiler
optimization, and the manually optimized code could not be optimized by the
compiler and was much worse than all other ones).

If there is still a bottleneck after all compiler optimization has been
done, start the profiler.


Tschau...Thomas

--- E3-32/1.11-32/2.51+
* Origin: Die TeX-Box +49-6034-930021 V.34 -930022 ISDN 24h (2:244/1130.42)
SEEN-BY: 50/99 54/99 270/101 620/243 625/110 160 711/401 413 430 808 934
SEEN-BY: 712/311 407 505 506 517 623 624 704 713/317 800/1
@PATH: 244/1130 1634 24/888 396/1 270/101 712/624 711/934

SOURCE: echomail via fidonet.ozzmosis.com

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.