[llvm] [Mips] Fix mfhi/mflo hazard miscompilation about div and mult (PR #91449)
YunQiang Su via llvm-commits
llvm-commits at lists.llvm.org
Mon Sep 9 17:27:26 PDT 2024
================
@@ -766,17 +769,40 @@ bool MipsBranchExpansion::handleSlot(Pred Predicate, Safe SafeInSlot) {
if (std::next(Iit) == FI->end() ||
std::next(Iit)->getOpcode() != Mips::NOP) {
Changed = true;
- TII->insertNop(*(I->getParent()), std::next(I), I->getDebugLoc())
- ->bundleWithPred();
- NumInsertedNops++;
+ if (Predicate(*I) ||
----------------
wzssyqa wrote:
Why this condition is added here?
I guess you need some comment or description in commit msg.
https://github.com/llvm/llvm-project/pull/91449
More information about the llvm-commits
mailing list