aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Transforms/Utils
diff options
context:
space:
mode:
authorDan Gohman <gohman@apple.com>2009-06-04 22:49:04 +0000
committerDan Gohman <gohman@apple.com>2009-06-04 22:49:04 +0000
commit7ce405e7aa026ef683da9eb8cc39cce87fcfa1d6 (patch)
tree768333097a76cc105813c7c636daf6259e6a0fc7 /lib/Transforms/Utils
parent66bd777e9009fd6a606532f9ed96745e86f3937c (diff)
downloadexternal_llvm-7ce405e7aa026ef683da9eb8cc39cce87fcfa1d6.zip
external_llvm-7ce405e7aa026ef683da9eb8cc39cce87fcfa1d6.tar.gz
external_llvm-7ce405e7aa026ef683da9eb8cc39cce87fcfa1d6.tar.bz2
Split the Add, Sub, and Mul instruction opcodes into separate
integer and floating-point opcodes, introducing FAdd, FSub, and FMul. For now, the AsmParser, BitcodeReader, and IRBuilder all preserve backwards compatability, and the Core LLVM APIs preserve backwards compatibility for IR producers. Most front-ends won't need to change immediately. This implements the first step of the plan outlined here: http://nondot.org/sabre/LLVMNotes/IntegerOverflow.txt git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@72897 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Transforms/Utils')
-rw-r--r--lib/Transforms/Utils/SimplifyCFG.cpp8
1 files changed, 2 insertions, 6 deletions
diff --git a/lib/Transforms/Utils/SimplifyCFG.cpp b/lib/Transforms/Utils/SimplifyCFG.cpp
index 2cde765..bcc6b81 100644
--- a/lib/Transforms/Utils/SimplifyCFG.cpp
+++ b/lib/Transforms/Utils/SimplifyCFG.cpp
@@ -419,9 +419,6 @@ static bool DominatesMergePoint(Value *V, BasicBlock *BB,
case Instruction::LShr:
case Instruction::AShr:
case Instruction::ICmp:
- case Instruction::FCmp:
- if (I->getOperand(0)->getType()->isFPOrFPVector())
- return false; // FP arithmetic might trap.
break; // These are all cheap and non-trapping instructions.
}
@@ -1012,9 +1009,8 @@ static bool SpeculativelyExecuteBB(BranchInst *BI, BasicBlock *BB1) {
default: return false; // Not safe / profitable to hoist.
case Instruction::Add:
case Instruction::Sub:
- // FP arithmetic might trap. Not worth doing for vector ops.
- if (HInst->getType()->isFloatingPoint()
- || isa<VectorType>(HInst->getType()))
+ // Not worth doing for vector ops.
+ if (isa<VectorType>(HInst->getType()))
return false;
break;
case Instruction::And: