runtime: RyuJIT: Volatile param shouldn't prevent inlining
[FAILED: argument has side effect] Math:Min(int,int):int
Math:Min(int,int):int doesn’t appear to have any side effect?
Related issue: https://github.com/dotnet/corefx/issues/11441 "ConcurrentQueue has Math.Min non-inlines "
About this issue
- Original URL
- State: closed
- Created 8 years ago
- Comments: 15 (15 by maintainers)
Commits related to this issue
- Allow inlining with volatile actual argument exprs When presented with an argument marked `GFT_ORDER_SIDEEFF`, mark the argument `argHasSideEff` and allow inlining. Remove the vestigial code to disa... — committed to JosephTremoulet/coreclr by JosephTremoulet 8 years ago
- Allow inlining with volatile actual argument exprs When presented with an argument marked `GFT_ORDER_SIDEEFF`, mark the argument `argHasSideEff` and allow inlining. Remove the vestigial code to disa... — committed to JosephTremoulet/coreclr by JosephTremoulet 8 years ago
- Allow inlining with volatile actual argument exprs When presented with an argument marked `GFT_ORDER_SIDEEFF`, mark the argument `argHasSideEff` and allow inlining. Remove the vestigial code to disa... — committed to JosephTremoulet/coreclr by JosephTremoulet 8 years ago
I tracked down the implementations of
impInlineSpillLclRefsandimpInlineSpillGlobEffects. It turns out the inliner used to have its own import loop, which didn’t handle as many cases, and for which those methods were trimmed-down versions ofimpSpillLclRefsandimpSpillSideEffects. Now that the inliner shares the main import loop with the importer, it’s using the full versions of those helpers which haveimpSpillSpecialSideEffcalls as needed to handle theGTF_ORDER_SIDEFFcases.Meanwhile, it looks like everything the inliner does for
argHasSideEffargs is something it needs to do for volatiles, and AFAIK is sufficient for them, so I’ll try testing the change to set it forGTF_ORDER_SIDEEFFarguments.