diff --git a/tools/llvm-exegesis/lib/X86/Target.cpp b/tools/llvm-exegesis/lib/X86/Target.cpp index 6ae228e1124..b74d5dcde9f 100644 --- a/tools/llvm-exegesis/lib/X86/Target.cpp +++ b/tools/llvm-exegesis/lib/X86/Target.cpp @@ -75,6 +75,9 @@ getMemoryOperandRanges(llvm::ArrayRef Operands) { static llvm::Error IsInvalidOpcode(const Instruction &Instr) { const auto OpcodeName = Instr.Name; + if ((Instr.Description->TSFlags & X86II::FormMask) == X86II::Pseudo) + return llvm::make_error( + "unsupported opcode: pseudo instruction"); if (OpcodeName.startswith("POPF") || OpcodeName.startswith("PUSHF") || OpcodeName.startswith("ADJCALLSTACK")) return llvm::make_error(