reactorlabs / rir

GNU General Public License v2.0
62 stars 18 forks source link

Revisit Recompilation Heuristic + nativeCallTrampoline #1298

Open skrynski opened 3 months ago

skrynski commented 3 months ago

We should revisit the recheck == 97 condition. It does not play well with the current recompilation heuristic which decides to recompile every PIR_WARMUP invocations to the function (currently 100), so both conditions must be true simultaneously. Also, recheck is a global variable and other calls most likely increase it in between. In other words, the chances it will trigger are low.

https://github.com/reactorlabs/rir/blob/95582fbabd054d0b2ea323539b4023c0f9bd4fb5/rir/src/compiler/native/builtins.cpp#L1416