The patch implements BLTZC, BLEZC, BGEZC and BGTZC instructions, fixes disassembly of all existing MicroMips B<cond>C implementations and adds offset checking to MipsR6 and MMR6 B<cond>C instructions.
Details
Diff Detail
Event Timeline
lib/Target/Mips/Disassembler/MipsDisassembler.cpp | ||
---|---|---|
651–663 | The current '* 2"s should be changed to '* 2 + 4'. | |
724–736 | Here too. | |
755 | Style point, you can put this line after the 'int64_t Imm..' line like the next function for consistency. | |
2392–2403 | Here again '* 2' -> '* 2 + 4'. | |
2437–2448 | Here again. | |
test/MC/Mips/micromips32r6/invalid.s | ||
301 | Add out of range tests as well, and unencodable offsets and to the other invalid test. |
And update the title/body to reflect that you've fixed the disassembly of all micromips b<cond>c instructions.
Added + 4 (where missing) to offsets when decoding B<cond>C instructions. Changed tests accordingly.
Added checking of offset range and alignment to B<cond>C instructions for MipsR6 and MMR6.
Added more invalid tests for B<cond>C instructions in MMR6 and MipsR6.
LGTM with the highlighted comment changed.
lib/Target/Mips/Disassembler/MipsDisassembler.cpp | ||
---|---|---|
2425 | if rs == 0 -> if rt == 0 |
The current '* 2"s should be changed to '* 2 + 4'.