The interface that AS use to interact with the JIT compiler for version 2. More...
Inherits asIJITCompilerAbstract.
Public Member Functions | |
virtual void | NewFunction (asIScriptFunction *scriptFunc)=0 |
Called by AngelScript when a new function is compiled. | |
virtual void | CleanFunction (asIScriptFunction *scriptFunc, asJITFunction jitFunc)=0 |
Called by AngelScript when the JIT function must be cleaned up. | |
This is the minimal interface that the JIT compiler must implement for version 2 so that AngelScript can request the compilation of the script functions.
|
pure virtual |
[in] | scriptFunc | The script function related to the JIT function |
[in] | jitFunc | The JIT function that was set by the JIT compiler for the script function |
AngelScript will call this either when the script function is being destroyed, or when a new JIT function is set on the script function, in which case the old JIT function must be cleaned up.
|
pure virtual |
[in] | scriptFunc | The script function that was just called |
AngelScript will call this function when a new script function is compiled.
The JIT compiler is not required to do the JIT compilation at this moment. Depending on the JIT compiler strategy it may be better to defer the JIT compilation until the full script has been compiled, so better global optimizations can be done.
When the JIT compilation is done, the JIT compiler must use asIScriptFunction::SetJITFunction to link the JIT function with the script function.