Reference interferes with optimization #58622
Labels
I-slow
Issue: Problems and improvements with respect to performance of generated code.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
(This comes from a Reddit thread.)
In the code below,
slow
takes double the timefast
takes. Ifprint
is changed to take a value rather than reference, the difference goes away.Timings:
The text was updated successfully, but these errors were encountered: