[llvm] [Xtensa] Implement branch analysis. (PR #110959)

Matt Arsenault via llvm-commits llvm-commits at lists.llvm.org
Thu Oct 10 22:05:10 PDT 2024


================
@@ -185,3 +185,301 @@ void XtensaInstrInfo::loadImmediate(MachineBasicBlock &MBB,
     report_fatal_error("Unsupported load immediate value");
   }
 }
+
+bool XtensaInstrInfo::reverseBranchCondition(
+    SmallVectorImpl<MachineOperand> &Cond) const {
+  assert(Cond.size() <= 4 && "Invalid branch condition!");
+
+  switch (Cond[0].getImm()) {
----------------
arsenm wrote:

Not sure all of these are tested? 

https://github.com/llvm/llvm-project/pull/110959


More information about the llvm-commits mailing list