[llvm] [X86][CodeGen] Support lowering for CCMP/CTEST (PR #91747)

Shengchen Kan via llvm-commits llvm-commits at lists.llvm.org
Sat May 25 22:01:50 PDT 2024


================
@@ -1801,11 +1801,8 @@ void DAGCombiner::Run(CombineLevel AtLevel) {
 
     if (N->getNumValues() == RV->getNumValues())
       DAG.ReplaceAllUsesWith(N, RV.getNode());
-    else {
-      assert(N->getValueType(0) == RV.getValueType() &&
-             N->getNumValues() == 1 && "Type mismatch");
----------------
KanRobert wrote:

Yes, we need. After changing `SUB ` to `CCMP`, neither of them satisfy.  For this case, `N->getValueType(1) == RV.getValueType() && N->getNumValues() == 2`

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


More information about the llvm-commits mailing list