[squeak-dev] Bug in PolygonMorph>>#filledForm

Nicolas Cellier nicolas.cellier.aka.nice at gmail.com
Fri Feb 21 21:48:22 UTC 2020


Interesting case to debug...
In 64bits VM, a problem first appears in first smear:distance: operation
(direction 1 at 0 to the right) at skew=16...

[image: Capture d’écran 2020-02-21 à 22.24.03.png]


It seems that we copy bits too far to the right (hence we overwrite the
bottom rows)
Fortunately, the artefacts outside polygon bounds disappear at final bitAnd
operation, but that's scary!

It could be:
- case of overlap detection failure (#checkSourceOverlap), but the code did
not change
- bad initialisation in #sourceSkewAndPointerInit (the one I corrected in
2019)
 https://github.com/OpenSmalltalk/opensmalltalk-vm/issues/426
- bug in #copyLoop (which I also corrected in 2019)
https://github.com/OpenSmalltalk/opensmalltalk-vm/issues/441

Weird kind of integer overflow? (I've made most of the int unsigned, so
this might not be detected by UB sanitizer).

Or could it be that the extra buffer overrun that I removed did have a side
effect of filling more gaps?
It would be interesting to observe what happens at same #smear:distance:
step with older VM.

Le ven. 21 févr. 2020 à 20:39, Stéphane Rollandin <lecteur at zogotounga.net>
a écrit :

> > Hmmm... the form was still filled in Squeak 5.1 (Update 16549),
> > VM 201701311639 (32-bit). Not so in Squeak 5.2.
>
> Yes, but that same 5.1 image with a current VM has the problem...
>
> Stef
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20200221/e999446a/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Capture d’écran 2020-02-21 à 22.24.03.png
Type: image/png
Size: 18235 bytes
Desc: not available
URL: <http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20200221/e999446a/attachment.png>


More information about the Squeak-dev mailing list