[Vm-dev] unit code for new faster bitblt

David T. Lewis lewis at mail.msen.com
Wed Jun 26 02:47:59 UTC 2013

On Tue, Jun 25, 2013 at 04:44:02PM -0700, tim Rowledge wrote:
> On 25-06-2013, at 4:38 PM, Casey Ransberger <casey.obrien.r at gmail.com> wrote:
> > 
> > Okay, just so I'm not burning all my bandwidth on snark here, is there a repo where I can look at all the code? 
> http://squeakvm.org/cgi-bin/viewvc.cgi/squeak/trunk/platforms/Cross/plugins/BitBltPlugin/

Speaking of which, although perhaps a bit off topic, I notice that there
are some issues in the Cross/plugins/BitBltPlugin code that are flagged as
compiler warnings when compiled on a 64-bit Linux platform. I can't offer
a fix, but I want to make you aware of them. The problems are related to
storing pointers into variables declared as uint32_t, which does not work
if pointers do not happen to be 32 bits long.

The problem areas are within some CPP macros, so it's hard for me to locate
them exactly. But here are some suspicious code snippets (edited for brevity):

        uint32_t halftone = 0;
        uint32_t *halftoneBase  = (uint32_t *) *op->halftoneBase;
        halftone = (halftoneBase + halftoneHeight);

So I expect that the halftone variable needs to be a pointer rather than
a uint32, and it looks like these pointers are later passed as function
parameters through CPP macros, and whatever they get passed to also need
to have the parameters declared as pointers rather than unit32 values.

Maybe you can pass this along to Ben, who will no doubt be able to make
better sense of it. None of this will affect a 32-bit platform, but it
will segfault on a 64-bit platform for sure.


More information about the Vm-dev mailing list