<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    <font face="Georgia">I thought I'd extend the test to an older
      squeak&amp;vm<br>
      <br>
      ---interpreter vm (3.8.12) squeak 3.2 ---------<br>
      Float compareTiming: 1 to: 1.0 ==&gt; 496<br>
      Float compareTiming: 1.0 to: 1.0 ==&gt; 761<br>
      Float compareTiming: 1 to: 1 ==&gt; 225<br>
      Float compareTiming: 1.0 to: 1 ==&gt; 494<br>
      ---interpreter vm (5.7.4.1) squeak 4.5 ---------<br>
      Float compareTiming: 1 to: 1.0 ==&gt; 719<br>
      Float compareTiming: 1.0 to: 1.0 ==&gt; 991<br>
      Float compareTiming: 1 to: 1 ==&gt; 312<br>
      Float compareTiming: 1.0 to: 1 ==&gt; 686<br>
      <br>
      The old one wins.<br>
      <br>
      Cheers,<br>
      Bob</font>
    <div class="moz-cite-prefix">On 9/27/13 2:12 PM, Bob Arning wrote:<br>
    </div>
    <blockquote cite="mid:5245CA86.1040400@comcast.net" type="cite">
      <meta content="text/html; charset=ISO-8859-1"
        http-equiv="Content-Type">
      Following up Herbert's question, I wrote:<br>
      <br>
      compareTiming: a to: b<br>
      "<br>
      ---interpreter vm (5.7.4.1) ---------<br>
      Float compareTiming: 1 to: 1.0 ==&gt; 719<br>
      Float compareTiming: 1.0 to: 1.0 ==&gt; 991<br>
      Float compareTiming: 1 to: 1 ==&gt; 312<br>
      Float compareTiming: 1.0 to: 1 ==&gt; 686<br>
      ---cog vm (2749)---------<br>
      <b>Float compareTiming: 1 to: 1.0&nbsp; ==&gt; 28162</b><br>
      Float compareTiming: 1.0 to: 1.0&nbsp; ==&gt; 148<br>
      Float compareTiming: 1 to: 1&nbsp; ==&gt; 97<br>
      Float compareTiming: 1.0 to: 1&nbsp; ==&gt; 179<br>
      "<br>
      &nbsp;&nbsp;&nbsp; <br>
      ^[1000000 timesRepeat: [ <br>
      &nbsp;&nbsp;&nbsp; a &lt; b.<br>
      &nbsp;&nbsp;&nbsp; a &lt; b.<br>
      &nbsp;&nbsp;&nbsp; a &lt; b.<br>
      &nbsp;&nbsp;&nbsp; a &lt; b.<br>
      &nbsp;&nbsp;&nbsp; a &lt; b.<br>
      &nbsp;&nbsp;&nbsp; a &lt; b.<br>
      &nbsp;&nbsp;&nbsp; a &lt; b.<br>
      &nbsp;&nbsp;&nbsp; a &lt; b.<br>
      &nbsp;&nbsp;&nbsp; a &lt; b.<br>
      &nbsp;&nbsp;&nbsp; a &lt; b.<br>
      &nbsp;&nbsp;&nbsp; a &lt; b.<br>
      &nbsp;&nbsp;&nbsp; a &lt; b.<br>
      &nbsp;&nbsp;&nbsp; a &lt; b.<br>
      &nbsp;&nbsp;&nbsp; a &lt; b.<br>
      &nbsp;&nbsp;&nbsp; a &lt; b.<br>
      &nbsp;&nbsp;&nbsp; a &lt; b.<br>
      &nbsp;&nbsp;&nbsp; a &lt; b.<br>
      &nbsp;&nbsp;&nbsp; a &lt; b.<br>
      &nbsp;&nbsp;&nbsp; a &lt; b.<br>
      &nbsp;&nbsp;&nbsp; a &lt; b.<br>
      &nbsp;&nbsp;&nbsp; a &lt; b.<br>
      &nbsp;&nbsp;&nbsp; a &lt; b.<br>
      &nbsp;&nbsp;&nbsp; a &lt; b.<br>
      &nbsp;&nbsp;&nbsp; a &lt; b.<br>
      &nbsp;&nbsp;&nbsp; a &lt; b.<br>
      &nbsp;&nbsp;&nbsp; a &lt; b.<br>
      &nbsp;&nbsp;&nbsp; a &lt; b.<br>
      &nbsp;&nbsp;&nbsp; a &lt; b.<br>
      &nbsp;&nbsp;&nbsp; a &lt; b.<br>
      &nbsp;&nbsp;&nbsp; a &lt; b.<br>
      ]] timeToRun<br>
      <br>
      So, some obvious questions:<br>
      - in the interpreter vm, why is comparing two floats slower that
      an integer and a float?<br>
      - what's up with Cog? Three tests are faster by the expected ratio
      and one took a real dive.<br>
      <br>
      Also, the profiler Herbert used could use some attention to the
      NewFloat printing:<br>
      <br>
      99.9 (898,069)&nbsp; Multiline1&nbsp; doOneStep:<br>
      &nbsp;&nbsp; <b>77.30000000000001</b> (694,902)&nbsp; Multiline1 [HkTestLine]&nbsp;
      doTests:<br>
      &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 73.8 (663,438)&nbsp; HkRunin [HkTestStation]&nbsp; canStartNextTest:<br>
      <br>
      Cheers,<br>
      Bob<br>
      <br>
    </blockquote>
    <br>
  </body>
</html>