summaryrefslogtreecommitdiffstats
path: root/llvm/lib
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2005-12-09 22:58:42 +0000
committerChris Lattner <sabre@nondot.org>2005-12-09 22:58:42 +0000
commit27656ac89cd0ea385fc668b496141eaae0905dfa (patch)
treebbfa5739cdc5dfa37381c73d253586324673c17a /llvm/lib
parent433573f4c67ce526d9988c2642d0cb0ffb46c46e (diff)
downloadbcm5719-llvm-27656ac89cd0ea385fc668b496141eaae0905dfa.tar.gz
bcm5719-llvm-27656ac89cd0ea385fc668b496141eaae0905dfa.zip
Add SDTCisPtrTy and use it for loads, to indicate that the operand of a load
must be a pointer. This removes a type check out of the code generated by tblgen for load matching. llvm-svn: 24650
Diffstat (limited to 'llvm/lib')
-rw-r--r--llvm/lib/Target/TargetSelectionDAG.td8
1 files changed, 5 insertions, 3 deletions
diff --git a/llvm/lib/Target/TargetSelectionDAG.td b/llvm/lib/Target/TargetSelectionDAG.td
index 996777f1ed8..e0585b756e2 100644
--- a/llvm/lib/Target/TargetSelectionDAG.td
+++ b/llvm/lib/Target/TargetSelectionDAG.td
@@ -24,15 +24,17 @@ class SDTypeConstraint<int opnum> {
}
// SDTCisVT - The specified operand has exactly this VT.
-class SDTCisVT <int OpNum, ValueType vt> : SDTypeConstraint<OpNum> {
+class SDTCisVT<int OpNum, ValueType vt> : SDTypeConstraint<OpNum> {
ValueType VT = vt;
}
+class SDTCisPtrTy<int OpNum> : SDTypeConstraint<OpNum>;
+
// SDTCisInt - The specified operand is has integer type.
class SDTCisInt<int OpNum> : SDTypeConstraint<OpNum>;
// SDTCisFP - The specified operand is has floating point type.
-class SDTCisFP <int OpNum> : SDTypeConstraint<OpNum>;
+class SDTCisFP<int OpNum> : SDTypeConstraint<OpNum>;
// SDTCisSameAs - The two specified operands have identical types.
class SDTCisSameAs<int OpNum, int OtherOp> : SDTypeConstraint<OpNum> {
@@ -132,7 +134,7 @@ def SDTWritePort : SDTypeProfile<0, 2, [ // writeport
]>;
def SDTLoad : SDTypeProfile<1, 1, [ // load
- SDTCisInt<1>
+ SDTCisPtrTy<1>
]>;
//===----------------------------------------------------------------------===//
OpenPOWER on IntegriCloud