[llvm] e04fe9a - [Statepoint] Fix bug found by sanitaizer.
Denis Antrushin via llvm-commits
llvm-commits at lists.llvm.org
Thu Jul 16 13:07:22 PDT 2020
Author: Denis Antrushin
Date: 2020-07-16T23:06:53+03:00
New Revision: e04fe9aefd4b95e0f0d93b14be28aa1ae2f42258
URL: https://github.com/llvm/llvm-project/commit/e04fe9aefd4b95e0f0d93b14be28aa1ae2f42258
DIFF: https://github.com/llvm/llvm-project/commit/e04fe9aefd4b95e0f0d93b14be28aa1ae2f42258.diff
LOG: [Statepoint] Fix bug found by sanitaizer.
Statepoint has no static operands, so it cannot be verified
against MCInstrDescr. Revert NumDefs change introduced by ef658ebd629.
Added:
Modified:
llvm/lib/CodeGen/MachineVerifier.cpp
Removed:
################################################################################
diff --git a/llvm/lib/CodeGen/MachineVerifier.cpp b/llvm/lib/CodeGen/MachineVerifier.cpp
index 63f534f20a71..c1a2c4e0bc6e 100644
--- a/llvm/lib/CodeGen/MachineVerifier.cpp
+++ b/llvm/lib/CodeGen/MachineVerifier.cpp
@@ -1565,9 +1565,6 @@ MachineVerifier::visitMachineOperand(const MachineOperand *MO, unsigned MONum) {
if (MCID.getOpcode() == TargetOpcode::PATCHPOINT)
NumDefs = (MONum == 0 && MO->isReg()) ? NumDefs : 0;
- if (MCID.getOpcode() == TargetOpcode::STATEPOINT)
- NumDefs = MI->getNumDefs();
-
// The first MCID.NumDefs operands must be explicit register defines
if (MONum < NumDefs) {
const MCOperandInfo &MCOI = MCID.OpInfo[MONum];
More information about the llvm-commits
mailing list