<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Thanks Eliot!<br>
<br>
On 27/03/2017 11:16 p.m., Eliot Miranda via Cuis-dev wrote:
<blockquote
cite="mid:B3CE955E-13AC-4219-B459-772E746A4CAA@gmail.com"
type="cite">
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<div><span></span></div>
<div>
<div><span></span></div>
<div>
<meta http-equiv="content-type" content="text/html;
charset=UTF-8">
<div>Hi All,</div>
<div id="AppleMailSignature"><br>
</div>
<div id="AppleMailSignature"> I have fixed a bug in the
compactor that accounts for the two cases I've analysed and
the two fairly repeatable crashes I have at hand (three
cases in all). I hope that all those who have been
experiencing crashes can start using the latest build asap.</div>
<div id="AppleMailSignature"><br>
</div>
<div id="AppleMailSignature">It is fixed in these commits:</div>
<div id="AppleMailSignature"><br>
</div>
<div id="AppleMailSignature"><span style="background-color:
rgba(255, 255, 255, 0);">Name: VMMaker.oscog-eem.2187<br>
Author: eem<br>
Time: 27 March 2017, 3:00:06.676146 pm<br>
UUID: 2259d299-65a4-42d0-a01b-4b25f5a89745<br>
Ancestors: VMMaker.oscog-rsf.2186<br>
<br>
SpurPlanningCompactor:<br>
Fix a big in resetting the free chunk used for the
firstUnusedFieldsSpace after non-final pasxses (i.e. on
snapshot). The old code didn't check to see if a free
chunk was actually found(!!).</span></div>
<div id="AppleMailSignature"><br>
</div>
<div id="AppleMailSignature">and</div>
<div id="AppleMailSignature"><br>
<span style="background-color: rgba(255, 255, 255, 0);">Branch:
refs/heads/Cog<br>
Home: <a moz-do-not-send="true"
href="https://github.com/OpenSmalltalk/opensmalltalk-vm"
dir="ltr" x-apple-data-detectors="true"
x-apple-data-detectors-type="link"
x-apple-data-detectors-result="0">https://github.com/OpenSmalltalk/opensmalltalk-vm</a><br>
Commit: 4ceff23323bcd0f2d3d0a4a43c2995f43d09c98a<br>
<a moz-do-not-send="true"
href="https://github.com/OpenSmalltalk/opensmalltalk-vm/commit/4ceff23323bcd0f2d3d0a4a43c2995f43d09c98a"
dir="ltr" x-apple-data-detectors="true"
x-apple-data-detectors-type="link"
x-apple-data-detectors-result="1">https://github.com/OpenSmalltalk/opensmalltalk-vm/commit/4ceff23323bcd0f2d3d0a4a43c2995f43d09c98a</a><br>
Author: Eliot Miranda <<a moz-do-not-send="true"
href="mailto:eliot.miranda@gmail.com" dir="ltr"
x-apple-data-detectors="true"
x-apple-data-detectors-type="link"
x-apple-data-detectors-result="2">eliot.miranda@gmail.com</a>><br>
Date: 2017-03-27 (Mon, 27 Mar 2017)</span></div>
<div id="AppleMailSignature"><br>
</div>
<div id="AppleMailSignature">The bintray files are here:</div>
<div id="AppleMailSignature"><a moz-do-not-send="true"
href="https://bintray.com/opensmalltalk/vm/cog/201703272314">https://bintray.com/opensmalltalk/vm/cog/201703272314</a><br>
<span style="background-color: rgba(255, 255, 255, 0);">_,,,^..^,,,_
(phone)</span></div>
<div><br>
On Mar 25, 2017, at 1:27 PM, Eliot Miranda <<a
moz-do-not-send="true"
href="mailto:eliot.miranda@gmail.com">eliot.miranda@gmail.com</a>>
wrote:<br>
<br>
</div>
<blockquote type="cite">
<div>
<div dir="ltr">Hi All,
<div><br>
</div>
<div> a number of people are being affected by
crashes on snapshotting the image, the worst possible
time for a crash. There is a bug in the new compactor
that unfortunately bites when saving. The compactor
is invoked as part of a full garbage collect after the
garbage collector has feed unreachable objects.
Normally the new compactor makes only a single pass
through the heap, which may not move all the objects
that are possible to move. (The amount of objects
that can be moved in a single pass is limited by
available free space.) But on snapshot the compactor
makes as may passes as are necessary to slide all
movable objects down as far as possible.
Unfortunately there is a bug in this second pass.</div>
<div><br>
</div>
<div>Fixing this bug is now my priority. I have an
example image from Esteban Lorenzano to test. I am
asking anyone else that can provide an image that
reliably crashes when trying to save it to make the
image and changes available to me for testing if
possible.</div>
<div><br>
</div>
<div>In the mean time one may be able to work around the
problem by doing a full garbage collect before
snapshot. This should do a GC with a single
compaction pass which should not fail, and then make
it much more likely that the GC during snapshot will
do a single compaction pass, since fewer objects
should be mobile after the single pass compaction in
the explicit GC.</div>
<div><br>
</div>
<div>To do this in Pharo I would put a full gc here:</div>
<div><br>
</div>
<div>
<div>SessionManager>>snapshot: save andQuit:
quit</div>
<div><span class="gmail-Apple-tab-span"
style="white-space: pre;"> </span>|
isImageStarting snapshotResult |</div>
<div><span class="gmail-Apple-tab-span"
style="white-space: pre;"> </span>ChangesLog
default logSnapshot: save andQuit: quit.</div>
<div><span class="gmail-Apple-tab-span"
style="white-space: pre;"><br>
</span></div>
<div><span class="gmail-Apple-tab-span"
style="white-space: pre;">>> SmalltalkImage
current primitiveGarbageCollect.</span></div>
<div><span class="gmail-Apple-tab-span"
style="white-space: pre;"><br>
</span></div>
<div><span class="gmail-Apple-tab-span"
style="white-space: pre;"> </span>self
currentSession stop: quit.<span
class="gmail-Apple-tab-span" style="white-space:
pre;"> </span>"Image not usable from here until
the session is restarted!"</div>
</div>
<div>...</div>
<div><br>
</div>
<div>In Squeak I would put a full GC here:</div>
<div><br>
</div>
<div>
<div>snapshot: save andQuit: quit withExitCode:
exitCode embedded: embeddedFlag</div>
<div><span class="gmail-Apple-tab-span"
style="white-space: pre;"> </span>"Mark the
changes file and close all files as part of
#processShutdownList.</div>
<div><span class="gmail-Apple-tab-span"
style="white-space: pre;"> </span>If save is
true, save the current state of this Smalltalk in
the image file.</div>
<div><span class="gmail-Apple-tab-span"
style="white-space: pre;"> </span>If quit is
true, then exit to the outer OS shell.</div>
<div><span class="gmail-Apple-tab-span"
style="white-space: pre;"> </span>If exitCode is
not nil, then use it as exit code.</div>
<div><span class="gmail-Apple-tab-span"
style="white-space: pre;"> </span>The latter part
of this method runs when resuming a previously saved
image. This resume logic checks for a document file
to process when starting up."</div>
<div><br>
</div>
<div><span class="gmail-Apple-tab-span"
style="white-space: pre;"> </span>| resuming msg
|</div>
<div><span class="gmail-Apple-tab-span"
style="white-space: pre;"> </span>Object
flushDependents.</div>
<div><span class="gmail-Apple-tab-span"
style="white-space: pre;"> </span>Object
flushEvents.</div>
<div><br>
</div>
<div><span style="white-space: pre;">...</span></div>
<div><span class="gmail-Apple-tab-span"
style="white-space: pre;"> </span>Smalltalk
processShutDownList: quit.</div>
<div>>><span style="white-space: pre;">
SmalltalkImage current primitiveGarbageCollect.</span></div>
<div><span class="gmail-Apple-tab-span"
style="white-space: pre;"> </span>Cursor write
show.</div>
<div><span class="gmail-Apple-tab-span"
style="white-space: pre;"> </span>save ifTrue:
[resuming := embeddedFlag </div>
<div><span class="gmail-Apple-tab-span"
style="white-space: pre;"> </span>ifTrue: [self
snapshotEmbeddedPrimitive] </div>
<div><span class="gmail-Apple-tab-span"
style="white-space: pre;"> </span>ifFalse: [self
snapshotPrimitive]] "<-- PC frozen here on image
file"</div>
<div><span class="gmail-Apple-tab-span"
style="white-space: pre;"> </span>ifFalse:
[resuming := false].</div>
</div>
<div><br>
</div>
<div>I do apologise for the bug. I hope it will be
fixed within a few days.</div>
<div><br>
</div>
<div class="gmail_signature">
<div dir="ltr">
<div><span style="font-size: small; border-collapse:
separate;">
<div>_,,,^..^,,,_<br>
</div>
<div>best, Eliot</div>
</span></div>
</div>
</div>
</div>
</div>
</blockquote>
</div>
</div>
<pre wrap="">
<fieldset class="mimeAttachmentHeader"></fieldset>
_______________________________________________
Cuis-dev mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Cuis-dev@cuis-smalltalk.org">Cuis-dev@cuis-smalltalk.org</a>
<a class="moz-txt-link-freetext" href="http://cuis-smalltalk.org/mailman/listinfo/cuis-dev_cuis-smalltalk.org">http://cuis-smalltalk.org/mailman/listinfo/cuis-dev_cuis-smalltalk.org</a>
</pre>
</blockquote>
<br>
<br>
<pre class="moz-signature" cols="72">--
Juan Vuletich
<a class="moz-txt-link-abbreviated" href="http://www.cuis-smalltalk.org">www.cuis-smalltalk.org</a>
<a class="moz-txt-link-freetext" href="https://github.com/Cuis-Smalltalk/Cuis-Smalltalk-Dev">https://github.com/Cuis-Smalltalk/Cuis-Smalltalk-Dev</a>
@JuanVuletich</pre>
</body>
</html>