Changes

Jump to navigation Jump to search
Line 87: Line 87:     
However annotations work differently in the compiled code, so SMAPI can't rewrite them. That means mods which use annotations are more fragile; they may break without warning in future game/SMAPI/Harmony updates, and may not work on some platforms.
 
However annotations work differently in the compiled code, so SMAPI can't rewrite them. That means mods which use annotations are more fragile; they may break without warning in future game/SMAPI/Harmony updates, and may not work on some platforms.
 +
 +
===What is inlining and why does it matter?===
 +
 +
[https://en.wikipedia.org/wiki/Inline_expansion Inlining] is when the JIT takes a method call and sticks the body of the function called instead of emitting an actual call. If this happens, a harmony patch applied to the callee will not take effect.
 +
 +
The heuristics the JIT uses to decide whether or not to inline a method are not documented and are subject to change, but [https://stackoverflow.com/a/31467000/19366602 small, simple methods that do not throw exceptions] are the most likely to be inlined. Additionally, the heuristic seems to change between platform and platform, with mac being more aggressive than Windows.
528

edits

Navigation menu