-
Notifications
You must be signed in to change notification settings - Fork 12.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[1.; 10] generates worse code than [1., 1., 1., 1., 1., 1., 1., 1., 1., 1.] #56333
Comments
We generate an explicit loop for all in-line repeat initializers which is why the codegen is usually worse compared to plain literals. |
I filed an llvm bug about this: https://bugs.llvm.org/show_bug.cgi?id=40011 |
Looking at the comment responding to that bug, it seems that it might be an LLVM pass ordering issue. Just curious, but is this something that we can fix or work around on our own fork of LLVM? Or is this a more general issue that will need to be resolved upstream? |
We prefer to have as few differences in our fork from upstream as possible, and what differences we have, must pull their weight to warrant backporting them every time we bump LLVM. |
Triage: no change |
This appears to be fixed by #81451 |
Here's an example
gives
which has an additional copy of the array.
The text was updated successfully, but these errors were encountered: