<div dir="ltr">Hi David,<div class="gmail_extra"><br><br><div class="gmail_quote">On Tue, Jan 1, 2013 at 12:24 PM, David T. Lewis <span dir="ltr">&lt;<a href="mailto:lewis@mail.msen.com" target="_blank">lewis@mail.msen.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">On Tue, Jan 01, 2013 at 03:47:54PM +0000, <a href="mailto:commits@source.squeak.org">commits@source.squeak.org</a> wrote:<br>

&gt; Nicolas Cellier uploaded a new version of Kernel to project The Trunk:<br>
&gt; <a href="http://source.squeak.org/trunk/Kernel-nice.725.mcz" target="_blank">http://source.squeak.org/trunk/Kernel-nice.725.mcz</a><br>
&gt;<br>
&gt; ==================== Summary ====================<br>
&gt;<br>
&gt; Name: Kernel-nice.725<br>
&gt; Author: nice<br>
&gt; Time: 1 January 2013, 4:47:30.911 pm<br>
&gt; UUID: 52a4994f-63bc-4f71-9f8f-6f2fad460bde<br>
&gt; Ancestors: Kernel-nice.724<br>
&gt;<br>
&gt; Fast-up large integer modulo operations (\\ and rem:)<br>
&gt;<br>
&gt; Implementation notes:<br>
&gt; Quotient and remainder are computed in a single LargeIntegersPlugin primitive (see digitDiv:neg:) so it&#39;s faster to just use it.<br>
&gt; For LargeInteger with 64 bits or less, LargeInteger primitives (31 32 33) are faster than the plugin (especially in COG) so try them first.<br>
&gt; This results in a 2x speed up of modulo operations in 4.2.5 VM (whatever bit length), and a 2x speed up in COG VM for bit length &gt; 64.<br>
&gt; There is a penalty of 15% in COG for #rem: when bit length &lt;= 64 because there is no primitiveRem...<br>
&gt; Well, I added primitiveRem and it is in both VM branches, but it has no primitive number assigned.<br>
&gt; If we assign a primitive number (20 ?) we can expect a 5x speed up for rem and bitLength &lt;= 64.<br>
<br>
Should we assign primitive number 20 to primitiveRemLargeIntegers? It is in<br>
the range of numbered primitives allocated for large integer prims, and is<br>
currently unused in both the interpreter VM and Cog.<br>
<br>
I can&#39;t think of any reason not to do this, so someone please speak up if<br>
it might cause problems.<br>
<br>
Eliot, is this ok for Cog and Newspeak etc?<br></blockquote><div><br></div><div>Fine by me.  20 isn&#39;t even used in Smalltalk-80 V2, and isn&#39;t by VisualWorks.  Seems ideal.</div></div>-- <br>best,<div>Eliot</div>
</div></div>