https://llvm.org/bugs/show_bug.cgi?id=30507
Bug ID: 30507 Summary: Disassembly asserts for certain invalid PowerPC instructions Product: libraries Version: 3.9 Hardware: PC OS: Linux Status: NEW Severity: normal Priority: P Component: Backend: PowerPC Assignee: unassignedb...@nondot.org Reporter: njholc...@wi.rr.com CC: llvm-bugs@lists.llvm.org Classification: Unclassified Calls to LLVMDisasmInstruction() with certain invalid PPC instructions fails due to assertions instead of returning an error. Below are 4 asserts that were hit, including example input bytes: Input: fe 47 c0 0a llvm/lib/Target/PowerPC/InstPrinter/PPCInstPrinter.cpp:256: void llvm::PPCInstPrinter::printU1ImmOperand(const llvm::MCInst*, unsigned int, llvm::raw_ostream&): Assertion `Value <= 1 && "Invalid u1imm argument!"' failed. Input: 12 d0 e2 0d llvm/lib/Target/PowerPC/InstPrinter/PPCInstPrinter.cpp:277: void llvm::PPCInstPrinter::printU4ImmOperand(const llvm::MCInst*, unsigned int, llvm::raw_ostream&): Assertion `Value <= 15 && "Invalid u4imm argument!"' failed. Input: 7f 1f ce 5d llvm/lib/Target/PowerPC/Disassembler/PPCDisassembler.cpp:210: DecodeStatus decodeRegisterClass(llvm::MCInst&, uint64_t, const unsigned int (&)[N]) [with long unsigned int N = 8ul; DecodeStatus = llvm::MCDisassembler::DecodeStatus; uint64_t = long unsigned int]: Assertion `RegNo < N && "Invalid register number"' failed. Input: 7c 96 36 1d llvm/include/llvm/MC/MCInst.h:75: int64_t llvm::MCOperand::getImm() const: Assertion `isImm() && "This is not an immediate"' failed. -- You are receiving this mail because: You are on the CC list for the bug.
_______________________________________________ llvm-bugs mailing list llvm-bugs@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs