[Vm-dev] Adding CPU specific code for fast bitblt on ARM

tim Rowledge tim at rowledge.org
Wed May 29 18:26:50 UTC 2013


On 29-05-2013, at 3:57 AM, "David T. Lewis" <lewis at mail.msen.com> wrote:
> 
> I started with a fresh platforms tree and VMMaker image, then added Ben's
> Cross/plugins/BitBltPlugin/* and unix/pluginx/BitBltPlugin/config.cmake.
> I also filed in your BitBltSimulation changes.
> 
> I did not file in the code generator changes, because VMMaker already has
> the following C preprocessor methods (http://bugs.squeak.org/view.php?id=5238):

Ah, excellent.I'll rewrite to make use of these. Um, so did you change the code to make use of them already?

> 
>   Object>>isDefined:inSmalltalk:comment:ifTrue:
>   Object>>isDefined:inSmalltalk:comment:ifTrue:ifFalse:
>   Object>>isDefinedTrueExpression:inSmalltalk:comment:ifTrue:ifFalse:
>   Object>>preprocessorExpression:
>   Object>>cPreprocessorDirective:
> 
> I compiled a VM for x86_64 Linux from this, both with and without the
> -DARM_FAST_BLT in CFLAGS. In both cases I got a working VM, and in both
> cases the code in Cross/plugins/BitBltPlugin was not compiled.

I think that is correct since the cmake fragment appears to explicitly check for arm

> 
> The configure and make commands that I used were:
>   $ cd build
>   $ ../platforms/unix/cmake/configure --src=../src --CFLAGS='-DARM_FAST_BLT'
>   $ make install
> 
> Conclusion: For Linux on a non-ARM platform, nothing bad happened when the
> code was added.

Sounds like a good start then.

> 
> I think that Cross/plugins/BitBltPlugin cries out for some naming convention
> or new directory structure to distinguish ARM from other platforms. I'm not
> sure what to suggest just now…

Me neither. Suggestions from the peanut gallery welcomed.

> 
> Regarding the code, is this available under MIT license? And who is this
> Ben guy anyhow ;-)

It's certainly intended to be acceptable to the main tree and the license verbiage looks MIT-ish to me. If it isn't adequate, I doubt there will be more than a five second conversation required to change it.

Ben is an ex-Acorn guy in the UK that happened to write the pixman Pi optimisations as well as quite a bit of RISC OS. As you will notice if you read the code, he is rather good at neat but devious code that does clever things to ARMs. For some reason despite living in Cambridge (the real one, not the one in the US) he works on PDT. He has a slightly dodgy beard.


tim
--
tim Rowledge; tim at rowledge.org; http://www.rowledge.org/tim
Strange OpCodes: IIB: Ignore Inquiry and Branch anyway




More information about the Vm-dev mailing list