<div dir="ltr"><div>On Wed, Aug 17, 2016 at 4:41 PM Eliot Miranda &lt;<a href="mailto:eliot.miranda@gmail.com">eliot.miranda@gmail.com</a>&gt; wrote:<br></div><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="auto"><div>I will generate and commit sources today.  If possible we should use the resulting VMs in the 5.1 release.  We have until early next week to test then harshly and see if they stand up to abuse ;-)<br></div></div></blockquote><div><br></div><div>So, shall we give this one a try then?</div><div><a href="https://bintray.com/opensmalltalk/vm/cog/201608171728#files">https://bintray.com/opensmalltalk/vm/cog/201608171728#files</a><br></div><div><br></div><div>Fabio</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="auto"><div><br><span style="background-color:rgba(255,255,255,0)">_,,,^..^,,,_ (phone)</span></div></div><div dir="auto"><div><br>On Aug 17, 2016, at 7:27 AM, Clément Bera &lt;<a href="mailto:bera.clement@gmail.com" target="_blank">bera.clement@gmail.com</a>&gt; wrote:<br><br></div><blockquote type="cite"><div><span></span></div></blockquote><blockquote type="cite"><div><div dir="ltr">With that commit the VM is stable again. </div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Aug 17, 2016 at 4:11 PM,  <span dir="ltr">&lt;<a href="mailto:commits@source.squeak.org" target="_blank">commits@source.squeak.org</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><br>
ClementBera uploaded a new version of VMMaker to project VM Maker:<br>
<a href="http://source.squeak.org/VMMaker/VMMaker.oscog-cb.1919.mcz" rel="noreferrer" target="_blank">http://source.squeak.org/VMMaker/VMMaker.oscog-cb.1919.mcz</a><br>
<br>
==================== Summary ====================<br>
<br>
Name: VMMaker.oscog-cb.1919<br>
Author: cb<br>
Time: 17 August 2016, 4:10:53.445475 pm<br>
UUID: 00a8dd2a-bc8d-4552-b400-be781c8aabec<br>
Ancestors: VMMaker.oscog-cb.1918<br>
<br>
fixed bug in scanner related to twoPath methods<br>
<br>
=============== Diff against VMMaker.oscog-cb.1918 ===============<br>
<br>
Item was changed:<br>
  ----- Method: StackToRegisterMappingCogit&gt;&gt;compileFrameBuild (in category &#39;compile abstract instructions&#39;) -----<br>
  compileFrameBuild<br>
        &quot;Build a frame for a CogMethod activation.  See CoInterpreter class&gt;&gt;initializeFrameIndices.<br>
         Override to push the register receiver and register arguments, if any.&quot;<br>
        self cppIf: IMMUTABILITY ifTrue:<br>
                [useTwoPaths ifTrue:<br>
                        [self compileTwoPathFrameBuild.<br>
                        ^self]].<br>
        needsFrame ifFalse:<br>
                [useTwoPaths ifTrue:<br>
                        [self compileTwoPathFramelessInit].<br>
                 self initSimStackForFramelessMethod: initialPC.<br>
                 ^self].<br>
+       self deny: useTwoPaths.<br>
        self genPushRegisterArgs.<br>
        super compileFrameBuild.<br>
        self initSimStackForFramefulMethod: initialPC!<br>
<br>
Item was changed:<br>
  ----- Method: StackToRegisterMappingCogit&gt;&gt;scanMethod (in category &#39;compile abstract instructions&#39;) -----<br>
  scanMethod<br>
        &quot;Scan the method (and all embedded blocks) to determine<br>
                - what the last bytecode is; extra bytes at the end of a method are used to encode things like source pointers or temp names<br>
                - if the method needs a frame or not<br>
                - what are the targets of any backward branches.<br>
                - how many blocks it creates<br>
         Answer the block count or on error a negative error code&quot;<br>
        | latestContinuation nExts descriptor pc numBlocks distance targetPC framelessStackDelta seenInstVarStore |<br>
        &lt;var: #descriptor type: #&#39;BytecodeDescriptor *&#39;&gt;<br>
        needsFrame := useTwoPaths := seenInstVarStore := false.<br>
        self maybeInitNumFixups.<br>
        self maybeInitNumCounters.<br>
        prevBCDescriptor := nil.<br>
        NewspeakVM ifTrue:<br>
                [numIRCs := 0].<br>
        (primitiveIndex &gt; 0<br>
         and: [coInterpreter isQuickPrimitiveIndex: primitiveIndex]) ifTrue:<br>
                [^0].<br>
        pc := latestContinuation := initialPC.<br>
        numBlocks := framelessStackDelta := nExts := extA := extB := 0.<br>
        [pc &lt;= endPC] whileTrue:<br>
                [byte0 := (objectMemory fetchByte: pc ofObject: methodObj) + bytecodeSetOffset.<br>
                 descriptor := self generatorAt: byte0.<br>
                 descriptor isExtension ifTrue:<br>
                        [descriptor opcode = Nop ifTrue: &quot;unknown bytecode tag; see Cogit class&gt;&gt;#generatorTableFrom:&quot;<br>
                                [^EncounteredUnknownBytecode].<br>
                         self loadSubsequentBytesForDescriptor: descriptor at: pc.<br>
                         self perform: descriptor generator].<br>
                 (descriptor isReturn<br>
                  and: [pc &gt;= latestContinuation]) ifTrue:<br>
                        [endPC := pc].<br>
<br>
                  needsFrame ifFalse:<br>
                        [(descriptor needsFrameFunction isNil<br>
                          or: [self perform: descriptor needsFrameFunction with: framelessStackDelta])<br>
                                        ifTrue:<br>
                                                [&quot;With immutability we win simply by avoiding a frame build if the receiver is young and not immutable.&quot;<br>
                                                 self cppIf: IMMUTABILITY<br>
                                                        ifTrue: [descriptor is1ByteInstVarStore<br>
                                                                        ifTrue: [useTwoPaths := true]<br>
                                                                        ifFalse: [needsFrame := true. useTwoPaths := false]]<br>
+                                                       ifFalse: [needsFrame := true. useTwoPaths := false]]<br>
-                                                       ifFalse: [needsFrame := true]]<br>
                                        ifFalse:<br>
                                                [framelessStackDelta := framelessStackDelta + descriptor stackDelta.<br>
                                                 &quot;Without immutability we win if there are two or more stores and the receiver is new.&quot;<br>
                                                 self cppIf: IMMUTABILITY<br>
                                                        ifTrue: []<br>
                                                        ifFalse:<br>
                                                                [descriptor is1ByteInstVarStore ifTrue:<br>
                                                                        [seenInstVarStore<br>
                                                                                ifTrue: [useTwoPaths := true]<br>
                                                                                ifFalse: [seenInstVarStore := true]]]]].<br>
<br>
                 descriptor isBranch ifTrue:<br>
                        [distance := self spanFor: descriptor at: pc exts: nExts in: methodObj.<br>
                         targetPC := pc + descriptor numBytes + distance.<br>
                         (self isBackwardBranch: descriptor at: pc exts: nExts in: methodObj)<br>
                                ifTrue: [self initializeFixupAt: targetPC - initialPC]<br>
                                ifFalse:<br>
                                        [latestContinuation := latestContinuation max: targetPC.<br>
                                         self maybeCountFixup.<br>
                                         self maybeCountCounter]].<br>
                 descriptor isBlockCreation ifTrue:<br>
                        [numBlocks := numBlocks + 1.<br>
                         distance := self spanFor: descriptor at: pc exts: nExts in: methodObj.<br>
                         targetPC := pc + descriptor numBytes + distance.<br>
                         latestContinuation := latestContinuation max: targetPC.<br>
                         self maybeCountFixup].<br>
<br>
                 NewspeakVM ifTrue:<br>
                        [descriptor hasIRC ifTrue:<br>
                                [numIRCs := numIRCs + 1]].<br>
                 pc := pc + descriptor numBytes.<br>
                 descriptor isExtension<br>
                        ifTrue: [nExts := nExts + 1]<br>
                        ifFalse: [nExts := extA := extB := 0].<br>
                 prevBCDescriptor := descriptor].<br>
        ^numBlocks!<br>
<br>
</blockquote></div><br></div>
</div></blockquote></div></blockquote></div></div>