diff --git a/llvm/lib/Target/X86/X86WinEHUnwindV2.cpp b/llvm/lib/Target/X86/X86WinEHUnwindV2.cpp index 7640d7090949..7fa77ee8204a 100644 --- a/llvm/lib/Target/X86/X86WinEHUnwindV2.cpp +++ b/llvm/lib/Target/X86/X86WinEHUnwindV2.cpp @@ -235,7 +235,7 @@ bool X86WinEHUnwindV2::runOnMachineFunction(MachineFunction &MF) { MF, Mode, "The epilog is popping more registers than the prolog " "pushed"); - if (PushedRegs[PushedRegs.size() - PoppedRegCount] != Reg) + if (PushedRegs[PushedRegs.size() - PoppedRegCount] != Reg.id()) return rejectCurrentFunctionInternalError( MF, Mode, "The epilog is popping a registers in "