aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Bitcode/Reader/BitcodeReader.cpp
diff options
context:
space:
mode:
authoranjenner <161845516+anjenner@users.noreply.github.com>2024-09-06 16:19:20 +0100
committerGitHub <noreply@github.com>2024-09-06 16:19:20 +0100
commit4af249fe6e81abd137c95bc25f5060ae305134ca (patch)
tree3cac4128f1db8c7e5dacab690448d3f4e12178e6 /llvm/lib/Bitcode/Reader/BitcodeReader.cpp
parent109cd11dc4aea6b3596f8b2cb5a719f35b190cfa (diff)
downloadllvm-4af249fe6e81abd137c95bc25f5060ae305134ca.zip
llvm-4af249fe6e81abd137c95bc25f5060ae305134ca.tar.gz
llvm-4af249fe6e81abd137c95bc25f5060ae305134ca.tar.bz2
Add usub_cond and usub_sat operations to atomicrmw (#105568)
These both perform conditional subtraction, returning the minuend and zero respectively, if the difference is negative.
Diffstat (limited to 'llvm/lib/Bitcode/Reader/BitcodeReader.cpp')
-rw-r--r--llvm/lib/Bitcode/Reader/BitcodeReader.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/llvm/lib/Bitcode/Reader/BitcodeReader.cpp b/llvm/lib/Bitcode/Reader/BitcodeReader.cpp
index 1cd9ec6..f887c9b 100644
--- a/llvm/lib/Bitcode/Reader/BitcodeReader.cpp
+++ b/llvm/lib/Bitcode/Reader/BitcodeReader.cpp
@@ -1349,6 +1349,10 @@ static AtomicRMWInst::BinOp getDecodedRMWOperation(unsigned Val) {
return AtomicRMWInst::UIncWrap;
case bitc::RMW_UDEC_WRAP:
return AtomicRMWInst::UDecWrap;
+ case bitc::RMW_USUB_COND:
+ return AtomicRMWInst::USubCond;
+ case bitc::RMW_USUB_SAT:
+ return AtomicRMWInst::USubSat;
}
}