diff options
author | Sean Silva <silvas@purdue.edu> | 2012-10-10 20:24:43 +0000 |
---|---|---|
committer | Sean Silva <silvas@purdue.edu> | 2012-10-10 20:24:43 +0000 |
commit | 6cfc806a6b82b60a3e923b6b89f2b4da62cdb50b (patch) | |
tree | 792b0800194da285c83f814a8ac1d93c59d0bcab /utils/TableGen/FastISelEmitter.cpp | |
parent | b0c6fa3b4b74d9cd03beb5a4cb9702abc85ac169 (diff) | |
download | llvm-6cfc806a6b82b60a3e923b6b89f2b4da62cdb50b.tar.gz llvm-6cfc806a6b82b60a3e923b6b89f2b4da62cdb50b.tar.bz2 llvm-6cfc806a6b82b60a3e923b6b89f2b4da62cdb50b.tar.xz |
tblgen: Mechanically move dynamic_cast<> to dyn_cast<>.
Some of these dyn_cast<>'s would be better phrased as isa<> or cast<>.
That will happen in a future patch.
There are also two dyn_cast_or_null<>'s slipped in instead of
dyn_cast<>'s, since they were causing crashes with just dyn_cast<>.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165646 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'utils/TableGen/FastISelEmitter.cpp')
-rw-r--r-- | utils/TableGen/FastISelEmitter.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/utils/TableGen/FastISelEmitter.cpp b/utils/TableGen/FastISelEmitter.cpp index ca784d0dda..c6d71ff8cf 100644 --- a/utils/TableGen/FastISelEmitter.cpp +++ b/utils/TableGen/FastISelEmitter.cpp @@ -245,7 +245,7 @@ struct OperandsSignature { if (Op->getType(0) != VT) return false; - DefInit *OpDI = dynamic_cast<DefInit*>(Op->getLeafValue()); + DefInit *OpDI = dyn_cast<DefInit>(Op->getLeafValue()); if (!OpDI) return false; Record *OpLeafRec = OpDI->getDef(); @@ -406,7 +406,7 @@ static std::string PhyRegForNode(TreePatternNode *Op, if (!Op->isLeaf()) return PhysReg; - DefInit *OpDI = dynamic_cast<DefInit*>(Op->getLeafValue()); + DefInit *OpDI = dyn_cast<DefInit>(Op->getLeafValue()); Record *OpLeafRec = OpDI->getDef(); if (!OpLeafRec->isSubClassOf("Register")) return PhysReg; @@ -473,7 +473,7 @@ void FastISelMap::collectPatterns(CodeGenDAGPatterns &CGP) { // a bit too complicated for now. if (!Dst->getChild(1)->isLeaf()) continue; - DefInit *SR = dynamic_cast<DefInit*>(Dst->getChild(1)->getLeafValue()); + DefInit *SR = dyn_cast<DefInit>(Dst->getChild(1)->getLeafValue()); if (SR) SubRegNo = getQualifiedName(SR->getDef()); else |