-
Notifications
You must be signed in to change notification settings - Fork 11.5k
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
Loop vectorizer causes error in backend (COMDAT symbol of string literal does not exist) #100076
Comments
When I uncomment this line: https://github.com/llvm/llvm-project/blob/llvmorg-18.1.7/llvm/lib/IR/ValueSymbolTable.cpp#L94 (Line 94) and call the compiler with
This happens in this stack:
The important place, where the symbol is rename, is in EndValue->setName("ind.end"); It seems like, that the associated COMDAT (member |
Problem Description
After upgrading from clang 14, we experience an error in the LLVM backend when compiling for
armv7a-none-windows-eabi
.The problem seems to be in the loop vectorizer and happens only with string literals that are longer than 15 characters.
It happens with clang 15, 16, 17, and 18.
The way the string buffer is allocated seems to be important, I was not able to reproduce the error when allocating the string buffer with "operator new".
Workaround
The code snippet in the repro steps includes an alternative implementation that apparently is optimized differently by the vectorizer.
Repro steps
Reproduce in Compiler Explorer
Compile the code snippet with the following command line arguments:
-Og -target armv7a-none-windows-eabi -fvectorize
Error Message
The text was updated successfully, but these errors were encountered: