diff options
author | Craig Topper <craig.topper@gmail.com> | 2015-05-14 05:53:53 +0000 |
---|---|---|
committer | Craig Topper <craig.topper@gmail.com> | 2015-05-14 05:53:53 +0000 |
commit | ec9072d661d00c1c869d63d9740f1d55d1c85393 (patch) | |
tree | d2e8a47f0bf55a4e75e404dfa2d280f7c670a4fd /llvm/utils/TableGen/CodeGenDAGPatterns.cpp | |
parent | e7aad46665c73f8e7c9d34f3d54013e1fc7e00ae (diff) | |
download | bcm5719-llvm-ec9072d661d00c1c869d63d9740f1d55d1c85393.tar.gz bcm5719-llvm-ec9072d661d00c1c869d63d9740f1d55d1c85393.zip |
[TableGen] Replace some calls to ListInit::getSize() with ListInit::empty() if it was just comparing to 0. NFC.
llvm-svn: 237340
Diffstat (limited to 'llvm/utils/TableGen/CodeGenDAGPatterns.cpp')
-rw-r--r-- | llvm/utils/TableGen/CodeGenDAGPatterns.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/utils/TableGen/CodeGenDAGPatterns.cpp b/llvm/utils/TableGen/CodeGenDAGPatterns.cpp index f03ef61b457..fd02bbdc6b4 100644 --- a/llvm/utils/TableGen/CodeGenDAGPatterns.cpp +++ b/llvm/utils/TableGen/CodeGenDAGPatterns.cpp @@ -3076,7 +3076,7 @@ void CodeGenDAGPatterns::ParseInstructions() { // null_frag operator is as-if no pattern were specified. Normally this // is from a multiclass expansion w/ a SDPatternOperator passed in as // null_frag. - if (!LI || LI->getSize() == 0 || hasNullFragReference(LI)) { + if (!LI || LI->empty() || hasNullFragReference(LI)) { std::vector<Record*> Results; std::vector<Record*> Operands; @@ -3399,7 +3399,7 @@ void CodeGenDAGPatterns::ParsePatterns() { Pattern->InlinePatternFragments(); ListInit *LI = CurPattern->getValueAsListInit("ResultInstrs"); - if (LI->getSize() == 0) continue; // no pattern. + if (LI->empty()) continue; // no pattern. // Parse the instruction. TreePattern Result(CurPattern, LI, false, *this); |