<div dir="ltr">Hi Esteban,<div class="gmail_extra"><br><div class="gmail_quote">On Mon, Oct 19, 2015 at 9:31 AM, Esteban Lorenzano <span dir="ltr">&lt;<a href="mailto:estebanlm@gmail.com" target="_blank">estebanlm@gmail.com</a>&gt;</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"> <br><div style="word-wrap:break-word"><div>Hi, </div><div><br></div><div>Does anyone tested Alien on Spur and &quot;El capitan&quot;? specifically callbacks?</div><div>For me, a completely broken :(</div><div><br></div><div>1) this structure (in maybeInlinePositive32BitIntegerFor: and others): </div><div><br></div><div><div><span style="white-space:pre-wrap">        </span>(integerValue &gt;= 0</div><div><span style="white-space:pre-wrap">        </span> and: [objectMemory isIntegerValue: integerValue]) ifTrue:</div><div><span style="white-space:pre-wrap">                </span>[^objectMemory integerObjectOf: integerValue].</div></div><div><br></div><div>Does not works if “integer value” is an unsigned long, because compiler assumes it will always be true, then remove the if, then answers a wrong value. </div></div></blockquote><div><br></div><div>Right, but oops are squints which are signed, so this shouldn&#39;t be a problem.  We can&#39;t safely cast the value to signed because, unless we know the size of the integer, we may truncate it.  e.g. (signed)integerValue is equivalent to (int)integerValue, and if integerValue were 64-bits the cast could cause the wrong answer.</div><div> </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 style="word-wrap:break-word"><div>2) <span style="font-size:11px;color:rgb(120,73,42);font-family:Menlo">assertCStackWellAligned </span>always fail. No idea why because if does not says anything, just jmp back to the regular flow. <br></div></div></blockquote><div><br></div><div>Put a breakpoint in warning and then you can see what the problem is.</div><div> </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 style="word-wrap:break-word"><div></div><div><br></div><div>3) finally, <span style="color:rgb(79,129,135);font-family:Menlo;font-size:11px">ceCaptureCStackPointers </span>also fails… this can be because (2) or because other reasons (it also jmps back so no clue) (method generateCaptureCStackPointers: clarifies is a hack, so I suppose it stopped to work). </div></div></blockquote><div><br></div><div>Right.  The stack should be properly aligned on a 128-bit/16-byte boundary for SSE instructions to work correctly.  So you need to step through the code generated for  <span style="font-size:14px;color:rgb(79,129,135);font-family:Menlo">ceCaptureCStackPointe</span><span style="font-size:14px;color:rgb(79,129,135);font-family:Menlo">rs,</span>and look at the execution state when <span style="color:rgb(120,73,42);font-family:Menlo;font-size:14px">assertCStackWellAligned</span>is evaluated.  For this you must use a debugger and puzzle out the code at the machine level.<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 style="word-wrap:break-word"><div>I guess solution of (1) is easy: argument number just has to be a sqLong instead an unsigned long. </div></div></blockquote><div><br></div><div>Right.  Extremely important :-)</div><div> </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 style="word-wrap:break-word"><div><br></div><div>But for 2 and 3 I have no idea where to start.</div><div><br></div><div>Does anyone has an idea?</div></div></blockquote><div><br></div><div>Roll your sleeves up and dive in with gdb/lldb.  And you can contact me via Skype or FaceTime if you want to talk it through and let me look over your shoulder.</div><div> </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 style="word-wrap:break-word"><div>Esteban<br></div></div></blockquote><div> </div></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>