diff options
author | Dan Gohman <gohman@apple.com> | 2008-12-03 02:30:17 +0000 |
---|---|---|
committer | Dan Gohman <gohman@apple.com> | 2008-12-03 02:30:17 +0000 |
commit | 41474baac839da410302950305722cb0e026a094 (patch) | |
tree | d36d696d3d8328b7c3db385d50c50f0ef584359f /lib/CodeGen/BranchFolding.cpp | |
parent | c70f3295438488e1e34eb212d1f8ec55bbf43935 (diff) |
Add a sanity-check to tablegen to catch the case where isSimpleLoad
is set but mayLoad is not set. Fix all the problems this turned up.
Change code to not use isSimpleLoad instead of mayLoad unless it
really wants isSimpleLoad.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@60459 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/BranchFolding.cpp')
-rw-r--r-- | lib/CodeGen/BranchFolding.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/CodeGen/BranchFolding.cpp b/lib/CodeGen/BranchFolding.cpp index aedd7c9be7..727f0a5cd1 100644 --- a/lib/CodeGen/BranchFolding.cpp +++ b/lib/CodeGen/BranchFolding.cpp @@ -414,7 +414,7 @@ static unsigned EstimateRuntime(MachineBasicBlock::iterator I, const TargetInstrDesc &TID = I->getDesc(); if (TID.isCall()) Time += 10; - else if (TID.isSimpleLoad() || TID.mayStore()) + else if (TID.mayLoad() || TID.mayStore()) Time += 2; else ++Time; |