[llvm] r367920 - Fix MSVC error after r367916
Daniel Sanders via llvm-commits
llvm-commits at lists.llvm.org
Mon Aug 5 13:03:44 PDT 2019
Author: dsanders
Date: Mon Aug 5 13:03:43 2019
New Revision: 367920
URL: http://llvm.org/viewvc/llvm-project?rev=367920&view=rev
Log:
Fix MSVC error after r367916
It seems that MSVC sees ambiguity between the operator==()'s where clang
doesn't
Modified:
llvm/trunk/lib/CodeGen/MachineBasicBlock.cpp
Modified: llvm/trunk/lib/CodeGen/MachineBasicBlock.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/MachineBasicBlock.cpp?rev=367920&r1=367919&r2=367920&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/MachineBasicBlock.cpp (original)
+++ llvm/trunk/lib/CodeGen/MachineBasicBlock.cpp Mon Aug 5 13:03:43 2019
@@ -499,7 +499,7 @@ MachineBasicBlock::addLiveIn(MCPhysReg P
// Look for an existing copy.
if (LiveIn)
for (;I != E && I->isCopy(); ++I)
- if (I->getOperand(1).getReg() == PhysReg) {
+ if (I->getOperand(1).getReg() == Register(PhysReg)) {
unsigned VirtReg = I->getOperand(0).getReg();
if (!MRI.constrainRegClass(VirtReg, RC))
llvm_unreachable("Incompatible live-in register class.");
More information about the llvm-commits
mailing list