<div dir="ltr">... at <a href="http://www.mirandabanda.org/files/Cog/VM/VM.r3163/">http://www.mirandabanda.org/files/Cog/VM/VM.r3163/</a>.<div><br></div><div><div>CogVM binaries as per VMMaker.oscog-eem.972/r3163<br></div><div><br></div><div>Fix a devilishly tricky bug with 32-bit Spur and PICs in the Cogit.  In 32-bit</div><div>Spur only zero is a valid cache tag, that for Characters, due to SmallIntegers</div><div>having both 2r11 and 2r01 as valid tags.  The cache check prolog collapses</div><div>these down onto 1 by anding with 1 and hence collapses Character&#39;s 2r10 to 0.</div><div><br></div><div>The cache tag is also tested in the PIC abort routine to distinguish between</div><div>an MNU abort and an interpret abort.  A PIC MNU entry jumps to code that first</div><div>zeros the cache tag (held in ClassReg) before calling the abort routine, which</div><div>tests ClassReg and selects the relevant abort processing.</div><div><br></div><div>Hence in 32-bit Spur if a send site is linked for Character and later extended</div><div>to a PIC with an interpret case, that interpret case will instead invoke MNU</div><div>processing.  This is rare; first there needs to be a send to a CHaracter, then</div><div>a send to something else which binds to something that must be interpreted.</div><div>Ouch.</div><div><br></div><div>The fix is simple; if a send site that was linked with a zero cache tag (which</div><div>can only happen in 32-bit Spur) link to an open PIC instead of to a closed PIC,</div><div>or in the case of an MNU do not link.</div><div><br></div><div>Add a debug lookup routine that only looks up (and follows forwarding pointers).</div><div><br></div><div>Add a -breakmnu vm argument that calls warning on an mnu of a specific selector.</div><div><br></div><div>Fix SmartSyntaxPlugin code generation for Spur of</div><div><br></div><div>- asOop: old code assumed 4 byte oops &amp; headers</div><div>- Unsigned old code assumed 32-bit oops</div><div><br></div><div><br></div><div>Affects AsyncFilePlugin, BochsIA32Plugin &amp; FT2Plgin.</div><div><br></div><div>Avoid duplication of effort in special selector send forwarding fault handling.</div><div><br></div><div>Improve stack trace printing for Newspeak and Glue by providing something that</div><div>assumes the penultimate literal is the selector or an AdditionalMethodState-like</div><div>thing containing it.</div><div><br></div><div>Reimplement primitiveCopyObject to work for both pointer and bits objects.</div><div>This to support a good Object&gt;&gt;clone for Spur.</div><div><br></div><div>Fix Spur&#39;s isWordsOrBytes[NonImm]:.  Old code answered true for CompiledMethods.</div>-- <br><div class="gmail_signature">best,<div>Eliot</div></div>
</div></div>