When disassembler meets cache/pref instructions for r6 it crashes as the access to operands array is out of range. This patch adds dedicated decoder method for R6 CACHE_HINT_DESC class that properly handles decoding of these instructions.
Details
Details
Diff Detail
Diff Detail
Event Timeline
Comment Actions
LGTM with a few nits
| lib/Target/Mips/Disassembler/MipsDisassembler.cpp | ||
|---|---|---|
| 256–258 | Nit: Indentation  | |
| 1120–1122 | Nit: Indentation  | |
| 1123 | Nit: Just for consistency, we should probably use 'fieldFromInstruction(Insn, 7, 9)' instead of '(Insn & 0xff90) >> 7'  | |
| 1127 | The same opcode is used for MIPS64r6 too. We should pick GPR32/GPR64 according to the subtarget  | |
| test/MC/Disassembler/Mips/mips32r6/valid-mips32r6-el.txt | ||
| 144 | Nit: Blank line at EOF  | |
| test/MC/Disassembler/Mips/mips32r6/valid-mips32r6.txt | ||
| 144 | Nit: Blank line at EOF  | |
| test/MC/Disassembler/Mips/mips64r6/valid-mips64r6-el.txt | ||
| 162 | Nit: Blank line at EOF  | |
| test/MC/Disassembler/Mips/mips64r6/valid-mips64r6.txt | ||
| 162 | Nit: Blank line at EOF  | |
Nit: Indentation