From: Evan Cheng Date: Fri, 6 Jul 2007 01:00:16 +0000 (+0000) Subject: Add OptionalDefOperand to stand for optionally defined result. X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=e496d78f16060ec4523a415bd62c8f010624dbac;p=oota-llvm.git Add OptionalDefOperand to stand for optionally defined result. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37930 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Target/Target.td b/lib/Target/Target.td index 723954b2e07..3d6d8363e45 100644 --- a/lib/Target/Target.td +++ b/lib/Target/Target.td @@ -263,14 +263,13 @@ def zero_reg; /// PredicateOperand - This can be used to define a predicate operand for an /// instruction. OpTypes specifies the MIOperandInfo for the operand, and /// AlwaysVal specifies the value of this predicate when set to "always -/// execute". If isOutput is true, then this is output operand. If isImmutable -/// is true, then the operand should not change after instruction selection. +/// execute". If isImmutable is true, then the operand should not change +/// after instruction selection. class PredicateOperand : Operand { let MIOperandInfo = OpTypes; - bit isOutput = 0; bit isImmutable = 0; - dag ExecuteAlways = AlwaysVal; + dag DefaultOps = AlwaysVal; } class ImmutablePredicateOperand @@ -278,9 +277,13 @@ class ImmutablePredicateOperand let isImmutable = 1; } -class PredicateDefOperand - : PredicateOperand { - let isOutput = 1; +/// OptionalDefOperand - This is used to define a optional definition operand +/// for an instruction. DefaultOps is the register the operand represents if none +/// is supplied, e.g. zero_reg. +class OptionalDefOperand + : Operand { + let MIOperandInfo = OpTypes; + dag DefaultOps = defaultops; }