summaryrefslogtreecommitdiffstats
path: root/llvm/lib/IR/Verifier.cpp
diff options
context:
space:
mode:
authorMatt Arsenault <Matthew.Arsenault@amd.com>2019-01-22 03:32:36 +0000
committerMatt Arsenault <Matthew.Arsenault@amd.com>2019-01-22 03:32:36 +0000
commitbfdba5e4fc351d3de15d5536a1d4e04a16573ddf (patch)
tree0d1dff23cf739d81409b302850eea4d890fd16b9 /llvm/lib/IR/Verifier.cpp
parent1eaa04d682d684f7e83c263aa40e78ae8faab378 (diff)
downloadbcm5719-llvm-bfdba5e4fc351d3de15d5536a1d4e04a16573ddf.tar.gz
bcm5719-llvm-bfdba5e4fc351d3de15d5536a1d4e04a16573ddf.zip
IR: Add fp operations to atomicrmw
Add just fadd/fsub for now. llvm-svn: 351778
Diffstat (limited to 'llvm/lib/IR/Verifier.cpp')
-rw-r--r--llvm/lib/IR/Verifier.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/llvm/lib/IR/Verifier.cpp b/llvm/lib/IR/Verifier.cpp
index fb2388c232b..1000e210533 100644
--- a/llvm/lib/IR/Verifier.cpp
+++ b/llvm/lib/IR/Verifier.cpp
@@ -3435,6 +3435,11 @@ void Verifier::visitAtomicRMWInst(AtomicRMWInst &RMWI) {
AtomicRMWInst::getOperationName(Op) +
" operand must have integer or floating point type!",
&RMWI, ElTy);
+ } else if (AtomicRMWInst::isFPOperation(Op)) {
+ Assert(ElTy->isFloatingPointTy(), "atomicrmw " +
+ AtomicRMWInst::getOperationName(Op) +
+ " operand must have floating point type!",
+ &RMWI, ElTy);
} else {
Assert(ElTy->isIntegerTy(), "atomicrmw " +
AtomicRMWInst::getOperationName(Op) +
OpenPOWER on IntegriCloud