[Gambas-user] 2 quickies

Jussi Lahtinen jussi.lahtinen at gmail.com
Mon Apr 27 01:52:26 CEST 2020


> 2-Wich is the correct way to use Fast providing:
>
> I have math functions called a lot at MouseMove events so I need them to
> be fast but to remain in memory
>
> so the Fast loading overhead time don't spoil its usage. I mean the
> funcion Fastenned is not that large, but its called
>
> say 10k times each MouseMove.
>
> I thougth using a module and declaring Static Fast.
>

Static does nothing for module, they are already static.  I suggest to test
function by function, which benefits from the JIT and only use it when
absolutely necessary.
Why the function is called 10k times at each MouseMove? Can you cache
anything  or calculate beforehand?


Jussi
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.gambas-basic.org/pipermail/user/attachments/20200427/7d4f91f0/attachment.html>


More information about the User mailing list