<html><head><meta http-equiv="content-type" content="text/html; charset=utf-8"></head><body dir="auto"><div><span></span></div><div><meta http-equiv="content-type" content="text/html; charset=utf-8"><div><span></span></div><div><meta http-equiv="content-type" content="text/html; charset=utf-8"><div><span></span></div><div><meta http-equiv="content-type" content="text/html; charset=utf-8"><pre><font face="UICTFontTextStyleBody"><span style="white-space: normal; background-color: rgba(255, 255, 255, 0);"> > It would take some time (more than I currently</span></font></pre><pre><font face="UICTFontTextStyleBody"><span style="white-space: normal; background-color: rgba(255, 255, 255, 0);"> > have!) to prove whether or not this is the case.</span></font></pre><pre><font face="UICTFontTextStyleBody"><span style="white-space: normal; background-color: rgba(255, 255, 255, 0);"> > suspect that there is no other single CASE in</span></font></pre><pre><font face="UICTFontTextStyleBody"><span style="white-space: normal; background-color: rgba(255, 255, 255, 0);"> > PO2013 that would have the same impact</span></font></pre><pre><font face="UICTFontTextStyleBody"><span style="white-space: normal; background-color: rgba(255, 255, 255, 0);"> > but there are a few areas in the compiler</span></font></pre><pre><font face="UICTFontTextStyleBody"><span style="white-space: normal; background-color: rgba(255, 255, 255, 0);"> > where CASE statements could be reinstated</span></font></pre><pre><font face="UICTFontTextStyleBody"><span style="white-space: normal; background-color: rgba(255, 255, 255, 0);"> > and the cumulative improvements could be significant. </span></font></pre><pre><font face="UICTFontTextStyleBody"><span style="white-space: normal; background-color: rgba(255, 255, 255, 0);"><br></span></font></pre><pre><font face="UICTFontTextStyleBody"><span style="white-space: normal; background-color: rgba(255, 255, 255, 0);">I like your systematic approach to such questions. Gives</span></font></pre><pre><font face="UICTFontTextStyleBody"><span style="white-space: normal; background-color: rgba(255, 255, 255, 0);">you hard data which form the basis of sound(er) arguments.</span></font></pre><pre><font face="UICTFontTextStyleBody"><span style="white-space: normal; background-color: rgba(255, 255, 255, 0);"><br></span></font></pre><pre><font face="UICTFontTextStyleBody"><span style="white-space: normal; background-color: rgba(255, 255, 255, 0);">As for the potential improvements in the compilation</span></font></pre><pre><font face="UICTFontTextStyleBody"><span style="white-space: normal; background-color: rgba(255, 255, 255, 0);">speed, my ingoing hypothesis would be that ORS.Get</span></font></pre><pre><font face="UICTFontTextStyleBody"><span style="white-space: normal; background-color: rgba(255, 255, 255, 0);">is where the biggest improvement is still to be expected,</span></font></pre><pre><font face="UICTFontTextStyleBody"><span style="white-space: normal; background-color: rgba(255, 255, 255, 0);">as it has the most cases. The others (ORP.StandFunc, ORP,StandProc and ORP.factor, etc) may </span></font><span style="white-space: normal; background-color: rgba(255, 255, 255, 0); font-family: UICTFontTextStyleBody;">cumulatively</span></pre><pre><font face="UICTFontTextStyleBody"><span style="white-space: normal; background-color: rgba(255, 255, 255, 0);">contribute another 5-10% or so perhaps. But hard</span></font></pre><pre><font face="UICTFontTextStyleBody"><span style="white-space: normal; background-color: rgba(255, 255, 255, 0);">to say without doing the</span></font><span style="white-space: normal; background-color: rgba(255, 255, 255, 0); font-family: UICTFontTextStyleBody;"> experiment.</span></pre><pre><font face="UICTFontTextStyleBody"><span style="white-space: normal; background-color: rgba(255, 255, 255, 0);"><br></span></font></pre><pre><font face="UICTFontTextStyleBody"><span style="white-space: normal; background-color: rgba(255, 255, 255, 0);">It would be </span></font><span style="white-space: normal; background-color: rgba(255, 255, 255, 0); font-family: UICTFontTextStyleBody;">instructive to construct something resembling</span></pre><pre><font face="UICTFontTextStyleBody"><span style="white-space: normal; background-color: rgba(255, 255, 255, 0);">the “space-time map”, as shown in Arthur Sale’s</span></font></pre><pre><font face="UICTFontTextStyleBody"><span style="white-space: normal; background-color: rgba(255, 255, 255, 0);">paper for modern RISC processors (or the RISC</span></font></pre><pre><font face="UICTFontTextStyleBody"><span style="white-space: normal; background-color: rgba(255, 255, 255, 0);">used in PO2013). The graph shown in the paper</span></font></pre><pre><font face="UICTFontTextStyleBody"><span style="white-space: normal; background-color: rgba(255, 255, 255, 0);">cannot really be used as a reliable quantitative proxy as</span></font></pre><pre><font face="UICTFontTextStyleBody"><span style="white-space: normal; background-color: rgba(255, 255, 255, 0);">the Burroughs </span></font><span style="white-space: normal; background-color: rgba(255, 255, 255, 0); font-family: UICTFontTextStyleBody;">7700 had special hardware support built in.</span></pre><pre><span style="white-space: normal; background-color: rgba(255, 255, 255, 0); font-family: UICTFontTextStyleBody;">Nevertheless, it’s an instructive qualitative insight.</span></pre><pre><span style="white-space: normal; background-color: rgba(255, 255, 255, 0); font-family: UICTFontTextStyleBody;"><br></span></pre><pre><pre><font face="UICTFontTextStyleBody"><span style="white-space: normal; background-color: rgba(255, 255, 255, 0);"> > However, this assumes that programmers have bothered</span></font></pre><pre><font face="UICTFontTextStyleBody"><span style="white-space: normal; background-color: rgba(255, 255, 255, 0);"> > to think about which branches are likely to occur more</span></font></pre><pre><font face="UICTFontTextStyleBody"><span style="white-space: normal; background-color: rgba(255, 255, 255, 0);"> > frequently and shuffle their IF-ELSIFs so they are near the top. </span></font></pre><pre><font face="UICTFontTextStyleBody"><span style="white-space: normal; background-color: rgba(255, 255, 255, 0);"><br></span></font></pre><pre><font face="UICTFontTextStyleBody"><span style="white-space: normal;">Or at least such that they roughly correspond to a “search tree” as described in </span></font><span style="font-family: UICTFontTextStyleBody; white-space: normal; background-color: rgba(255, 255, 255, 0);">Arthur Sale's paper. ORS.Get in PO2013 is an example, but it’s not perfect, because there, the subranges don’t lead to an optimum comparison tree.</span></pre><pre><span style="font-family: UICTFontTextStyleBody; white-space: normal; background-color: rgba(255, 255, 255, 0);"><br></span></pre><pre><span style="font-family: UICTFontTextStyleBody; white-space: normal; background-color: rgba(255, 255, 255, 0);"><br></span></pre><pre><pre><font face="UICTFontTextStyleBody"><span style="white-space: normal; background-color: rgba(255, 255, 255, 0);"><br></span></font></pre></pre></pre></div></div></div></body></html>