| Issue |
161104
|
| Summary |
Missing `isCall` and `isBranch` flags for RISCV instructions
|
| Labels |
new issue
|
| Assignees |
|
| Reporter |
moste00
|
The common root class `Instruction` defines several flags to roughly classify the semantics of an instruction, among them is an `isCall` and `isBranch` flags. https://github.com/llvm/llvm-project/blob/d29798767cc10a0609b5f1f9f75f032b6760cf50/llvm/include/llvm/Target/Target.td#L646
<img width="1191" height="793" alt="Image" src="" />
This flag is not set correctly in the definition of the `JAL` and the `JALR` instruction [in RISCVInstrInfo.td](https://github.com/llvm/llvm-project/blob/d29798767cc10a0609b5f1f9f75f032b6760cf50/llvm/lib/Target/RISCV/RISCVInstrInfo.td#L755)
<img width="1121" height="769" alt="Image" src="" />
The instruction `C_JR` also doesn't have the `isBranch` flag set [ in RISCVInstrInfoC.td](https://github.com/llvm/llvm-project/blob/d29798767cc10a0609b5f1f9f75f032b6760cf50/llvm/lib/Target/RISCV/RISCVInstrInfoC.td#L489)
<img width="1121" height="287" alt="Image" src="" />
_______________________________________________
llvm-bugs mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs