[TwoAddressInstruction] Remove ad hoc machine verification
authorJay Foad <jay.foad@amd.com>
Tue, 12 Oct 2021 08:15:07 +0000 (09:15 +0100)
committerJay Foad <jay.foad@amd.com>
Tue, 12 Oct 2021 15:09:18 +0000 (16:09 +0100)
With the -early-live-intervals command line flag,
TwoAddressInstructionPass::runOnMachineFunction would call
MachineFunction::verify before returning to check the live intervals.
But there was not much benefit to doing this since -verify-machineinstrs
and LLVM_ENABLE_EXPENSIVE_CHECKS provide a more general way of
scheduling machine verification after every pass.

Also it caused problems on targets like Lanai which are marked as "not
machine verifier clean", since verification would fail for known
target-specific problems which are nothing to do with LiveIntervals.

Differential Revision: https://reviews.llvm.org/D111618

llvm/lib/CodeGen/TwoAddressInstructionPass.cpp

index 23e1685..461d25e 100644 (file)
@@ -1742,9 +1742,6 @@ bool TwoAddressInstructionPass::runOnMachineFunction(MachineFunction &Func) {
     }
   }
 
-  if (LIS)
-    MF->verify(this, "After two-address instruction pass");
-
   return MadeChange;
 }