Open
Description
In rust-lang/literal-escaper#15 I introduced NonZero into literal-escaper, but noticed perf regressions (on ARM).
On compiler explorer I noticed x86_64 asm differences that seem to indicate there may be a difference in inlining behavior: asm being generated without code differences in the surrounding code (does that not mean it is dead?). These can indeed be removed by uncommenting the commented #[inline]
directives (top left pane). On arm, the changes are similar but more extensive and I can't tell whether extra function code is called or not.
Sprinkling the right #[inline]
directives does remove the perf regressions on ARM. I haven't been able to do perf measurements on x86_64 yet.