From: Alex Bradbury <asb@lowrisc.org>
Date: Thu, 18 Jul 2019 07:52:41 +0000 (+0000)
Subject: [RISCV] Reset NoPHIS MachineFunctionProperty in emitSelectPseudo
X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=ce02d1c4d8976eefeb1ec59280a27df8cd0b4877;p=llvm

[RISCV] Reset NoPHIS MachineFunctionProperty in emitSelectPseudo

We insered PHIS were there were none before, so the property must be
reset. This error was found on an EXPENSIVE_CHECKS build.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@366412 91177308-0d34-0410-b5e6-96231b3b80d8
---

diff --git a/lib/Target/RISCV/RISCVISelLowering.cpp b/lib/Target/RISCV/RISCVISelLowering.cpp
index 5d8a2b0a650..ce7b85911ab 100644
--- a/lib/Target/RISCV/RISCVISelLowering.cpp
+++ b/lib/Target/RISCV/RISCVISelLowering.cpp
@@ -1308,6 +1308,7 @@ static MachineBasicBlock *emitSelectPseudo(MachineInstr &MI,
     SelectMBBI = Next;
   }
 
+  F->getProperties().reset(MachineFunctionProperties::Property::NoPHIs);
   return TailMBB;
 }