forked from OSchip/llvm-project
Instructions with ImmutablePredicateOperand aren't really predicable since their predicates are fixed at isel time.
llvm-svn: 37899
This commit is contained in:
parent
94f04c6fc9
commit
e32e7fb40d
|
@ -411,7 +411,10 @@ CodeGenInstruction::CodeGenInstruction(Record *R, const std::string &AsmStr)
|
|||
if (unsigned NumArgs = MIOpInfo->getNumArgs())
|
||||
NumOps = NumArgs;
|
||||
|
||||
isPredicable |= Rec->isSubClassOf("PredicateOperand");
|
||||
if (Rec->isSubClassOf("PredicateOperand")) {
|
||||
if (!Rec->getValueAsBit("isImmutable"))
|
||||
isPredicable = true;
|
||||
}
|
||||
} else if (Rec->getName() == "variable_ops") {
|
||||
hasVariableNumberOfOperands = true;
|
||||
continue;
|
||||
|
|
|
@ -107,7 +107,8 @@ InstrInfoEmitter::GetOperandInfo(const CodeGenInstruction &Inst) {
|
|||
|
||||
// Predicate operands. Check to see if the original unexpanded operand
|
||||
// was of type PredicateOperand.
|
||||
if (Inst.OperandList[i].Rec->isSubClassOf("PredicateOperand"))
|
||||
if (Inst.OperandList[i].Rec->isSubClassOf("PredicateOperand") &&
|
||||
!Inst.OperandList[i].Rec->getValueAsBit("isImmutable"))
|
||||
Res += "|M_PREDICATE_OPERAND";
|
||||
|
||||
// Fill in constraint info.
|
||||
|
|
Loading…
Reference in New Issue