<div dir="ltr">Hello folks. I was riding on a surfboard when I jumped over this little shark, which seems perchance at least useful as food for thought. It purportedly converts MASM (which uses an Intel-style syntax) to the AT&amp;T style. It might just work, though more likely we&#39;d have to tweak it to understand various idiosyncrasies of ASASM.<div>
<br></div><div style>I was somewhat surprised by how short the script is; it&#39;s certainly much smaller than the amount of assembler code, which suggests that automatically converting it may be a viable solution after all, and we&#39;d avoid both losing signal to a disassembler, as well as the work of a manual translation. I&#39;d been thinking of tackling it with OMeta/JS if I didn&#39;t find anything else to use, but then I saw this:</div>
<div style><br></div><div style><a href="http://www.delorie.com/djgpp/mail-archives/djgpp/1995/06/06/05:48:34">http://www.delorie.com/djgpp/mail-archives/djgpp/1995/06/06/05:48:34</a><br></div></div><div class="gmail_extra">
<br><br><div class="gmail_quote">On Tue, Jun 25, 2013 at 7:47 PM, David T. Lewis <span dir="ltr">&lt;<a href="mailto:lewis@mail.msen.com" target="_blank">lewis@mail.msen.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="im"><br>
On Tue, Jun 25, 2013 at 04:44:02PM -0700, tim Rowledge wrote:<br>
&gt;<br>
&gt;<br>
&gt; On 25-06-2013, at 4:38 PM, Casey Ransberger &lt;<a href="mailto:casey.obrien.r@gmail.com">casey.obrien.r@gmail.com</a>&gt; wrote:<br>
&gt; &gt;<br>
&gt; &gt; Okay, just so I&#39;m not burning all my bandwidth on snark here, is there a repo where I can look at all the code?<br>
&gt;<br>
&gt;<br>
&gt; <a href="http://squeakvm.org/cgi-bin/viewvc.cgi/squeak/trunk/platforms/Cross/plugins/BitBltPlugin/" target="_blank">http://squeakvm.org/cgi-bin/viewvc.cgi/squeak/trunk/platforms/Cross/plugins/BitBltPlugin/</a><br>
&gt;<br>
<br>
</div>Speaking of which, although perhaps a bit off topic, I notice that there<br>
are some issues in the Cross/plugins/BitBltPlugin code that are flagged as<br>
compiler warnings when compiled on a 64-bit Linux platform. I can&#39;t offer<br>
a fix, but I want to make you aware of them. The problems are related to<br>
storing pointers into variables declared as uint32_t, which does not work<br>
if pointers do not happen to be 32 bits long.<br>
<br>
The problem areas are within some CPP macros, so it&#39;s hard for me to locate<br>
them exactly. But here are some suspicious code snippets (edited for brevity):<br>
<br>
        uint32_t halftone = 0;<br>
        uint32_t *halftoneBase  = (uint32_t *) *op-&gt;halftoneBase;<br>
        halftone = (halftoneBase + halftoneHeight);<br>
<br>
So I expect that the halftone variable needs to be a pointer rather than<br>
a uint32, and it looks like these pointers are later passed as function<br>
parameters through CPP macros, and whatever they get passed to also need<br>
to have the parameters declared as pointers rather than unit32 values.<br>
<br>
Maybe you can pass this along to Ben, who will no doubt be able to make<br>
better sense of it. None of this will affect a 32-bit platform, but it<br>
will segfault on a 64-bit platform for sure.<br>
<br>
Dave<br>
<br>
<br>
</blockquote></div><br><br clear="all"><div><br></div>-- <br>Casey Ransberger
</div>