[llvm] [Xtensa] Implement lowering SELECT_CC, SETCC. (PR #97017)

Andrei Safronov via llvm-commits llvm-commits at lists.llvm.org
Sat Jul 6 17:23:40 PDT 2024


================
@@ -90,6 +90,22 @@ XtensaTargetLowering::XtensaTargetLowering(const TargetMachine &TM,
   setOperationAction(ISD::BR_CC, MVT::i64, Expand);
   setOperationAction(ISD::BR_CC, MVT::f32, Expand);
 
+  // Used by legalize types to correctly generate the setcc result.
+  setOperationPromotedToType(ISD::SETCC, MVT::i1, MVT::i32);
+  setOperationPromotedToType(ISD::BR_CC, MVT::i1, MVT::i32);
----------------
andreisfr wrote:

@s-barannikov , thank you very much for comments. I removed this code and add more tests for branches.

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


More information about the llvm-commits mailing list