<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Sun, Mar 12, 2017 at 3:04 AM, Guillermo Polito <span dir="ltr"><<a href="mailto:guillermopolito@gmail.com" target="_blank">guillermopolito@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div dir="ltr">Yeh, to be more precise, <div>* the problem is that the image somehow got it's display size modified to a very small one. </div><div>* And that happenned while building an image in the CI in headless mode. </div><div>* If the same image is built locally in a vm launched in non-headless mode, the issue cannot be reproduced.</div><div><br></div><div>So my conjecture is that</div><div>- either the image is changing the display size while loading pillar (less likely and not reproduceable locally)</div><div>- either the latest stable VM messes the display size in the image header when running on headless (this is yet to reproduce)</div></div></blockquote><div><br></div><div>I'm pretty confident this is to do with bugs in the Athens surface code which assumes that callbacks can be made in the existing copyBits and warpBits primitive.  They can't do this safely because a GC (scavenge) can happen during a callback, which then causes chaos when the copyBits primitive tries to access objects that have been moved under its feet.</div><div><br></div><div>I've done work to fix callbacks so that when there is a failure it is the copyBits primitive that fails, instead of apparently the callback return primitive.  One of the apparent effects of this fix is to stop the screen opening up too small; another is getting the background colour right, and yet another is eliminating bogus pixels in the VGTigerDemo demo.  But more work is required to fix the copyBits and warpBits primitives.  There are a few approaches one might take:</div><div><br></div><div>a)  fixing the primitive so that it saves and restores oops around the callbacks using the external pop table.  That's a pain but possible.</div><div><br></div><div>b) fixing the primitive so that it pins the objects it needs before ever invoking a callback</div><div><br></div><div>c) fixing the primitive so that it uses the scavenge and fullGC counters in the VM to detect if a GC occurred during one of the callbacks and would fail the primitive.   The primitive would then simply be retried. </div><div><br></div><div>d) ?</div><div><br></div><div>I like c) as it's very lightweight, but it has issues.  It is fine to use for callbacks *before* cop[yBits and warpBits move any bits (the lockSurface and querySurface functions).  But it's potentially erroneous after the unlockSurface primitive.  For example, a primitive which does an xor with the screen can't simply be retried as the first, falling pass, would have updated the destination bits but not displayed them via unlockSurface.  But I think it could be arranged that no objects are accessed after unlockSurface, which should naturally be the last call in the primitive (or do I mean showSurface?).  So the approach would be to check for GCs occurring during querySurface and lockSurface, failing if so, and then caching any and all state needed by unlockSurface and showSurface in local variables.  This way no object state is accessed to make the unlockSurface and showSurface calls, and no bits are moved before the queryDurface and lockSurface calls.</div><div><br></div><div>If we used a failure code such as #'object may move' then the primitives could answer this when a GC during callbacks is detected and then the primitive could be retried only when required.</div><div><br></div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div class="gmail-HOEnZb"><div class="gmail-h5"><div class="gmail_extra"><br><div class="gmail_quote">On Sun, Mar 12, 2017 at 10:52 AM, stepharong <span dir="ltr"><<a href="mailto:stepharong@free.fr" target="_blank">stepharong@free.fr</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">guillermo was suspecting a problem with the interpretatin of the image metadata<br>
<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
Maybe related?<br>
<a href="http://forum.world.st/BUG-A-problem-with-callbacks-that-shows-up-in-64bits-but-is-on-32bits-too-td4938152.html" rel="noreferrer" target="_blank">http://forum.world.st/BUG-A-pr<wbr>oblem-with-callbacks-that-show<wbr>s-up-in-64bits-but-is-on-32bit<wbr>s-too-td4938152.html</a><br>
<br>
On Sat, Mar 11, 2017 at 2:22 AM, Cyril Ferlicot<br>
<<a href="mailto:cyril.ferlicot@gmail.com" target="_blank">cyril.ferlicot@gmail.com</a>> wrote:<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
<br>
On ven. 10 mars 2017 at 18:42, stepharong <<a href="mailto:stepharong@free.fr" target="_blank">stepharong@free.fr</a>> wrote:<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
<br>
We found the problem with Guillermo and this may be a problem of the last<br>
VM.<br>
<br>
The image got its starting window size really small: some pixels on some<br>
pixles.<br>
So may be the metadata of the image are systematically corrupted.<br>
<br>
Hi<br>
<br>
I have a jenkins that produce an image that does not start<br>
when I try to open it locally.<br>
<br>
Now if I take the image and load the "same" configuration I get a working<br>
image<br>
<br>
I have not idea how to debug that.<br>
<br>
Stef<br>
<br>
<br>
<br>
<br>
--<br>
Using Opera's mail client: <a href="http://www.opera.com/mail/" rel="noreferrer" target="_blank">http://www.opera.com/mail/</a><br>
</blockquote>
<br>
<br>
If it can help: here is the build:<br>
<br>
<a href="https://ci.inria.fr/pharo-contribution/job/OOnoz/" rel="noreferrer" target="_blank">https://ci.inria.fr/pharo-cont<wbr>ribution/job/OOnoz/</a><br>
<br>
It is happening in almost all Pharo 6 builds<span class="gmail-m_-1970735252508657042HOEnZb"><font color="#888888"><br>
--<br>
Cheers<br>
Cyril Ferlicot<br>
</font></span></blockquote><span class="gmail-m_-1970735252508657042HOEnZb"><font color="#888888">
<br>
</font></span></blockquote><span class="gmail-m_-1970735252508657042HOEnZb"><font color="#888888">
<br>
<br>
-- <br>
Using Opera's mail client: <a href="http://www.opera.com/mail/" rel="noreferrer" target="_blank">http://www.opera.com/mail/</a><br>
<br>
</font></span></blockquote></div><br></div>
</div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br><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>