JIT: Prevent generic context runaway during inlining of polymorphic recursive methods#90306
JIT: Prevent generic context runaway during inlining of polymorphic recursive methods#90306jakobbotsch merged 5 commits intodotnet:mainfrom
Conversation
…ecursive methods The inliner heuristics do not take into account that inlining methods causes type/method loading of the generic context. After dotnet#88749 this can quickly cause significant resources to be consumed as part of inlining when polymorphic recursion is involved (the blow-up can be exponential, as we see in the failing test under jitstress). This PR adds another safe-guard to the recursive inlining check in terms of a complexity limit on the generic context of the inline candidate. Fix dotnet#90144
|
Tagging subscribers to this area: @JulieLeeMSFT, @jakobbotsch Issue DetailsThe inliner heuristics do not take into account that inlining methods causes type/method loading of the generic context. After #88749 this can quickly cause significant resources to be consumed as part of inlining when polymorphic recursion is involved (the blow-up can be exponential, as we see in the failing test under jitstress). This PR adds another safe-guard to the recursive inlining check in terms of a complexity limit on the generic context of the inline candidate. Fix #90144
|
|
/azp run runtime-coreclr jitstress, runtime-coreclr libraries-jitstress |
|
Azure Pipelines successfully started running 2 pipeline(s). |
Co-authored-by: Jan Kotas <[email protected]>
|
cc @dotnet/jit-contrib PTAL @EgorBo (and @AndyAyersMS if available) |
|
PTAL @agocke @MichalStrehovsky . |
|
Ah I didn't notice you already had it 🙂 don't know how to cancel |
The inliner heuristics do not take into account that inlining methods causes type/method loading of the generic context. After #88749 this can quickly cause significant resources to be consumed as part of inlining when polymorphic recursion is involved (the blow-up can be exponential, as we see in the failing test under jitstress).
This PR adds another safe-guard to the recursive inlining check in terms of a complexity limit on the generic context of the inline candidate.
Fix #90144