Open mkannwischer opened 1 month ago
@llvm/issue-subscribers-backend-arm
Author: Matthias J. Kannwischer (mkannwischer)
There is a reproducer here: https://godbolt.org/z/1eb7E3Ecr
It looks like ARMAsmParser::processInstruction alters the instruction, in a way that might not be the same as the non-w version.
I have the following piece of Arm Cortex-M4 assembly (or any armv7-m CPU really) in
input.asm
:If I am running
llvm-mca --mcpu=cortex-m4 --march=arm < input.asm
, I'm getting:If I remove the
.w
it works fine and I am getting the expected result.I do understand that the
.w
is not useful here, as the post-increment str results in the 32-bit T4 encoding anyway, I'd still not expect a crash like this.I'm running llvm from the arch linux repo: https://archlinux.org/packages/extra/x86_64/llvm/
I've also tried compiling llvm from source on a recent commit (
c791d86eab13634ec372196977eeac8f3e9f4805
), but that also results in a crash