[llvm] [RISCV] 'Zalrsc' may permit non-base instructions (PR #165042)
Francesco Petrogalli via llvm-commits
llvm-commits at lists.llvm.org
Fri Oct 24 15:59:38 PDT 2025
================
@@ -682,6 +702,9 @@ bool RISCVExpandAtomicPseudo::expandAtomicMinMaxOp(
MachineBasicBlock &MBB, MachineBasicBlock::iterator MBBI,
AtomicRMWInst::BinOp BinOp, bool IsMasked, int Width,
MachineBasicBlock::iterator &NextMBBI) {
+ // Using MIN(U)/MAX(U) is preferrable if permitted
+ if (STI->hasPermissiveZalrsc() && STI->hasStdExtZbb() && !IsMasked)
----------------
fpetrogalli wrote:
yeah but assertions come for free, and very helpful when they fire unexpectedly
https://github.com/llvm/llvm-project/pull/165042
More information about the llvm-commits
mailing list