Login  Register

Re: NativeBoost : optimisation of the machine code generation

Posted by kilon.alios on Aug 07, 2014; 4:39pm
URL: https://forum.world.st/NativeBoost-optimisation-of-the-machine-code-generation-tp4772327p4772358.html

I think that if you posted the code , preferably that contains only the problem would be easier to test , debug and investigate. 



On Thu, Aug 7, 2014 at 6:25 PM, Thomas Bany <[hidden email]> wrote:
Hi everyone,

I'm trying to reduce the computation time of the following pseudo-code:

- memory allocation (~40 doubles)
- object heap to C heap copying
- NativeBoost call (nbCall:)
- memory freeing

The time profiling results are bellow:

- 24*3600 calls : > 1 minute
- 24*3600 calls with only memory allocation and copying : < 1 second
- 1 call with a 24*3600 loop inside de C code : < 1 second

So it appears that the very coslty step is the transition from Pharo to C. And I was wondering if it was possible to drasticly reduce this time by doing something like, generate the the machine code once and call it multiple time ?

Thanks in advance !

Thomas.