[llvm] [InstCombine] Fix undef widening in masked-merge (PR #219212)

via llvm-commits llvm-commits at lists.llvm.org
Thu Aug 27 08:35:22 PDT 2026


github-actions[bot] wrote:

<!--PREMERGE ADVISOR COMMENT: Linux-->
# :penguin: Linux x64 Test Results

* 181412 tests passed
* 3741 tests skipped
* 2 tests failed

## Failed Tests
(click on a test name to see its output)

### LLVM
<details>
<summary>LLVM.CodeGen/X86/znver-pdep.ll (Likely Already Failing)</summary>
This test is already failing at the base commit.

```
Exit Code: 1

Command Output (stdout):
--
# RUN: at line 2
/home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/llc < /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/CodeGen/X86/znver-pdep.ll -mtriple=x86_64-- -mcpu=znver1 | /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/FileCheck /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/CodeGen/X86/znver-pdep.ll --check-prefixes=CHECK,SLOW-ZNVER
# executed command: /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/llc -mtriple=x86_64-- -mcpu=znver1
# note: command had no output on stdout or stderr
# executed command: /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/FileCheck /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/CodeGen/X86/znver-pdep.ll --check-prefixes=CHECK,SLOW-ZNVER
# .---command stderr------------
# | /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/CodeGen/X86/znver-pdep.ll:1013:15: error: CHECK-NEXT: is not on the line after the previous match
# | ; CHECK-NEXT: pdepl %eax, %ecx, %eax
# |               ^
# | <stdin>:495:2: note: 'next' match was here
# |  pdepl %eax, %ecx, %eax
# |  ^
# | <stdin>:493:19: note: previous match ended here
# |  vmovd %xmm0, %edx
# |                   ^
# | <stdin>:494:1: note: non-matching line after previous match is here
# |  vpextrd $2, %xmm0, %esi
# | ^
# | /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/CodeGen/X86/znver-pdep.ll:1036:15: error: CHECK-NEXT: is not on the line after the previous match
# | ; CHECK-NEXT: vpextrd $1, %xmm2, %eax
# |               ^
# | <stdin>:519:2: note: 'next' match was here
# |  vpextrd $1, %xmm2, %eax
# |  ^
# | <stdin>:516:31: note: previous match ended here
# |  vextracti128 $1, %ymm1, %xmm2
# |                               ^
# | <stdin>:517:1: note: non-matching line after previous match is here
# |  vpextrd $1, %xmm0, %r8d
# | ^
# | /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/CodeGen/X86/znver-pdep.ll:1079:15: error: CHECK-NEXT: expected string not found in input
# | ; CHECK-NEXT: vmovq %xmm1, %rdx
# |               ^
# | <stdin>:559:25: note: scanning from here
# |  vpextrq $1, %xmm0, %rcx
# |                         ^
# | <stdin>:561:2: note: possible intended match here
# |  vmovq %xmm0, %rdx
# |  ^
# | /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/CodeGen/X86/znver-pdep.ll:1096:15: error: CHECK-NEXT: expected string not found in input
# | ; CHECK-NEXT: vpextrq $1, %xmm1, %rsi
# |               ^
# | <stdin>:576:31: note: scanning from here
# |  vextracti128 $1, %ymm0, %xmm3
# |                               ^
# | <stdin>:585:2: note: possible intended match here
# |  vpextrq $1, %xmm1, %rax
# |  ^
# | 
# | Input file: <stdin>
# | Check file: /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/CodeGen/X86/znver-pdep.ll
# | 
# | -dump-input=help explains the following input dump.
# | 
# | Input was:
# | <<<<<<
# |              .
# |              .
# |              .
# |            488:  .type pdep_v4i32_minsize, at function 
# |            489: pdep_v4i32_minsize: # @pdep_v4i32_minsize 
# |            490: # %bb.0: 
# |            491:  vpextrd $1, %xmm1, %eax 
# |            492:  vpextrd $1, %xmm0, %ecx 
# |            493:  vmovd %xmm0, %edx 
# | next:1013'0                      {   search range start (exclusive)
# |            494:  vpextrd $2, %xmm0, %esi 
# |            495:  pdepl %eax, %ecx, %eax 
# | next:1013'1      !~~~~~~~~~~~~~~~~~~~~~   error: match on wrong line
# |            496:  vmovd %xmm1, %ecx 
# |            497:  pdepl %ecx, %edx, %ecx 
# |            498:  vpextrd $2, %xmm1, %edx 
# |            499:  pdepl %edx, %esi, %edx 
# |            500:  vpextrd $3, %xmm0, %esi 
# |              .
# |              .
# |              .
# |            508: .Lfunc_end4: 
# |            509:  .size pdep_v4i32_minsize, .Lfunc_end4-pdep_v4i32_minsize 
# |            510:  # -- End function 
# |            511:  .globl pdep_v8i32_minsize # -- Begin function pdep_v8i32_minsize 
# |            512:  .type pdep_v8i32_minsize, at function 
# |            513: pdep_v8i32_minsize: # @pdep_v8i32_minsize 
# | next:1013'2                        }                        search range end (exclusive)
# |            514: # %bb.0: 
# |            515:  vextracti128 $1, %ymm0, %xmm3 
# |            516:  vextracti128 $1, %ymm1, %xmm2 
# | next:1036'0                                  {   search range start (exclusive)
# |            517:  vpextrd $1, %xmm0, %r8d 
# |            518:  vmovd %xmm0, %r9d 
# |            519:  vpextrd $1, %xmm2, %eax 
# | next:1036'1      !~~~~~~~~~~~~~~~~~~~~~~   error: match on wrong line
# |            520:  vpextrd $1, %xmm3, %ecx 
# |            521:  vmovd %xmm3, %edx 
# |            522:  vpextrd $2, %xmm3, %esi 
# |            523:  vpextrd $3, %xmm3, %edi 
# |            524:  pdepl %eax, %ecx, %eax 
# |              .
# |              .
# |              .
# |            551: .Lfunc_end5: 
# |            552:  .size pdep_v8i32_minsize, .Lfunc_end5-pdep_v8i32_minsize 
# |            553:  # -- End function 
# |            554:  .globl pdep_v2i64_minsize # -- Begin function pdep_v2i64_minsize 
# |            555:  .type pdep_v2i64_minsize, at function 
# |            556: pdep_v2i64_minsize: # @pdep_v2i64_minsize 
# | next:1036'2                        }                        search range end (exclusive)
# |            557: # %bb.0: 
# |            558:  vpextrq $1, %xmm1, %rax 
# |            559:  vpextrq $1, %xmm0, %rcx 
# | next:1079'0                            {   search range start (exclusive)
# | next:1079'1                                error: no match found in search range
# |            560:  vmovq %xmm1, %rsi 
# |            561:  vmovq %xmm0, %rdx 
# | next:1079'2      ?                   possible intended match
# |            562:  pdepq %rax, %rcx, %rax 
# |            563:  pdepq %rsi, %rdx, %rcx 
# |            564:  vmovq %rax, %xmm0 
# |            565:  vmovq %rcx, %xmm1 
# |            566:  vpunpcklqdq %xmm0, %xmm1, %xmm0 # xmm0 = xmm1[0],xmm0[0] 
# |            567:  retq 
# |            568: .Lfunc_end6: 
# |            569:  .size pdep_v2i64_minsize, .Lfunc_end6-pdep_v2i64_minsize 
# |            570:  # -- End function 
# |            571:  .globl pdep_v4i64_minsize # -- Begin function pdep_v4i64_minsize 
# |            572:  .type pdep_v4i64_minsize, at function 
# |            573: pdep_v4i64_minsize: # @pdep_v4i64_minsize 
# | next:1079'3                        }                        search range end (exclusive)
# |            574: # %bb.0: 
# |            575:  vextracti128 $1, %ymm1, %xmm2 
# |            576:  vextracti128 $1, %ymm0, %xmm3 
# | next:1096'0                                  {   search range start (exclusive)
# | next:1096'1                                      error: no match found in search range
# |            577:  vpextrq $1, %xmm2, %rax 
# |            578:  vpextrq $1, %xmm3, %rcx 
# |            579:  vmovq %xmm2, %rsi 
# |            580:  vmovq %xmm3, %rdx 
# |            581:  pdepq %rax, %rcx, %rax 
# |            582:  pdepq %rsi, %rdx, %rcx 
# |            583:  vpextrq $1, %xmm0, %rdx 
# |            584:  vmovq %rax, %xmm2 
# |            585:  vpextrq $1, %xmm1, %rax 
# | next:1096'2      ?                         possible intended match
# |            586:  vmovq %rcx, %xmm3 
# |            587:  vmovq %xmm0, %rcx 
# |            588:  pdepq %rax, %rdx, %rax 
# |            589:  vmovq %xmm1, %rdx 
# |            590:  vpunpcklqdq %xmm2, %xmm3, %xmm2 # xmm2 = xmm3[0],xmm2[0] 
# |              .
# |              .
# |              .
# |            595:  vinserti128 $1, %xmm2, %ymm0, %ymm0 
# |            596:  retq 
# |            597: .Lfunc_end7: 
# |            598:  .size pdep_v4i64_minsize, .Lfunc_end7-pdep_v4i64_minsize 
# |            599:  # -- End function 
# |            600:  .section ".note.GNU-stack","", at progbits 
# | next:1096'3                                              } search range end (exclusive)
# | >>>>>>
# `-----------------------------
# error: command failed with exit status: 1

--

```
</details>
<details>
<summary>LLVM.CodeGen/X86/znver-pext.ll (Likely Already Failing)</summary>
This test is already failing at the base commit.

```
Exit Code: 1

Command Output (stdout):
--
# RUN: at line 2
/home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/llc < /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/CodeGen/X86/znver-pext.ll -mtriple=x86_64-- -mcpu=znver1 | /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/FileCheck /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/CodeGen/X86/znver-pext.ll --check-prefixes=CHECK,SLOW
# executed command: /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/llc -mtriple=x86_64-- -mcpu=znver1
# note: command had no output on stdout or stderr
# executed command: /home/gha/actions-runner/_work/llvm-project/llvm-project/build/bin/FileCheck /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/CodeGen/X86/znver-pext.ll --check-prefixes=CHECK,SLOW
# .---command stderr------------
# | /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/CodeGen/X86/znver-pext.ll:594:15: error: CHECK-NEXT: is not on the line after the previous match
# | ; CHECK-NEXT: pextl %eax, %ecx, %eax
# |               ^
# | <stdin>:495:2: note: 'next' match was here
# |  pextl %eax, %ecx, %eax
# |  ^
# | <stdin>:493:19: note: previous match ended here
# |  vmovd %xmm0, %edx
# |                   ^
# | <stdin>:494:1: note: non-matching line after previous match is here
# |  vpextrd $2, %xmm0, %esi
# | ^
# | /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/CodeGen/X86/znver-pext.ll:617:15: error: CHECK-NEXT: is not on the line after the previous match
# | ; CHECK-NEXT: vpextrd $1, %xmm2, %eax
# |               ^
# | <stdin>:519:2: note: 'next' match was here
# |  vpextrd $1, %xmm2, %eax
# |  ^
# | <stdin>:516:31: note: previous match ended here
# |  vextracti128 $1, %ymm1, %xmm2
# |                               ^
# | <stdin>:517:1: note: non-matching line after previous match is here
# |  vpextrd $1, %xmm0, %r8d
# | ^
# | /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/CodeGen/X86/znver-pext.ll:660:15: error: CHECK-NEXT: expected string not found in input
# | ; CHECK-NEXT: vmovq %xmm1, %rdx
# |               ^
# | <stdin>:559:25: note: scanning from here
# |  vpextrq $1, %xmm0, %rcx
# |                         ^
# | <stdin>:561:2: note: possible intended match here
# |  vmovq %xmm0, %rdx
# |  ^
# | /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/CodeGen/X86/znver-pext.ll:677:15: error: CHECK-NEXT: expected string not found in input
# | ; CHECK-NEXT: vpextrq $1, %xmm1, %rsi
# |               ^
# | <stdin>:576:31: note: scanning from here
# |  vextracti128 $1, %ymm0, %xmm3
# |                               ^
# | <stdin>:585:2: note: possible intended match here
# |  vpextrq $1, %xmm1, %rax
# |  ^
# | 
# | Input file: <stdin>
# | Check file: /home/gha/actions-runner/_work/llvm-project/llvm-project/llvm/test/CodeGen/X86/znver-pext.ll
# | 
# | -dump-input=help explains the following input dump.
# | 
# | Input was:
# | <<<<<<
# |             .
# |             .
# |             .
# |           488:  .type pext_v4i32_minsize, at function 
# |           489: pext_v4i32_minsize: # @pext_v4i32_minsize 
# |           490: # %bb.0: 
# |           491:  vpextrd $1, %xmm1, %eax 
# |           492:  vpextrd $1, %xmm0, %ecx 
# |           493:  vmovd %xmm0, %edx 
# | next:594'0                      {   search range start (exclusive)
# |           494:  vpextrd $2, %xmm0, %esi 
# |           495:  pextl %eax, %ecx, %eax 
# | next:594'1      !~~~~~~~~~~~~~~~~~~~~~   error: match on wrong line
# |           496:  vmovd %xmm1, %ecx 
# |           497:  pextl %ecx, %edx, %ecx 
# |           498:  vpextrd $2, %xmm1, %edx 
# |           499:  pextl %edx, %esi, %edx 
# |           500:  vpextrd $3, %xmm0, %esi 
# |             .
# |             .
# |             .
# |           508: .Lfunc_end4: 
# |           509:  .size pext_v4i32_minsize, .Lfunc_end4-pext_v4i32_minsize 
# |           510:  # -- End function 
# |           511:  .globl pext_v8i32_minsize # -- Begin function pext_v8i32_minsize 
# |           512:  .type pext_v8i32_minsize, at function 
# |           513: pext_v8i32_minsize: # @pext_v8i32_minsize 
# | next:594'2                        }                        search range end (exclusive)
# |           514: # %bb.0: 
# |           515:  vextracti128 $1, %ymm0, %xmm3 
# |           516:  vextracti128 $1, %ymm1, %xmm2 
# | next:617'0                                  {   search range start (exclusive)
# |           517:  vpextrd $1, %xmm0, %r8d 
# |           518:  vmovd %xmm0, %r9d 
# |           519:  vpextrd $1, %xmm2, %eax 
# | next:617'1      !~~~~~~~~~~~~~~~~~~~~~~   error: match on wrong line
# |           520:  vpextrd $1, %xmm3, %ecx 
# |           521:  vmovd %xmm3, %edx 
# |           522:  vpextrd $2, %xmm3, %esi 
# |           523:  vpextrd $3, %xmm3, %edi 
# |           524:  pextl %eax, %ecx, %eax 
# |             .
# |             .
# |             .
# |           551: .Lfunc_end5: 
# |           552:  .size pext_v8i32_minsize, .Lfunc_end5-pext_v8i32_minsize 
# |           553:  # -- End function 
# |           554:  .globl pext_v2i64_minsize # -- Begin function pext_v2i64_minsize 
# |           555:  .type pext_v2i64_minsize, at function 
# |           556: pext_v2i64_minsize: # @pext_v2i64_minsize 
# | next:617'2                        }                        search range end (exclusive)
# |           557: # %bb.0: 
# |           558:  vpextrq $1, %xmm1, %rax 
# |           559:  vpextrq $1, %xmm0, %rcx 
# | next:660'0                            {   search range start (exclusive)
# | next:660'1                                error: no match found in search range
# |           560:  vmovq %xmm1, %rsi 
# |           561:  vmovq %xmm0, %rdx 
# | next:660'2      ?                   possible intended match
# |           562:  pextq %rax, %rcx, %rax 
# |           563:  pextq %rsi, %rdx, %rcx 
# |           564:  vmovq %rax, %xmm0 
# |           565:  vmovq %rcx, %xmm1 
# |           566:  vpunpcklqdq %xmm0, %xmm1, %xmm0 # xmm0 = xmm1[0],xmm0[0] 
# |           567:  retq 
# |           568: .Lfunc_end6: 
# |           569:  .size pext_v2i64_minsize, .Lfunc_end6-pext_v2i64_minsize 
# |           570:  # -- End function 
# |           571:  .globl pext_v4i64_minsize # -- Begin function pext_v4i64_minsize 
# |           572:  .type pext_v4i64_minsize, at function 
# |           573: pext_v4i64_minsize: # @pext_v4i64_minsize 
# | next:660'3                        }                        search range end (exclusive)
# |           574: # %bb.0: 
# |           575:  vextracti128 $1, %ymm1, %xmm2 
# |           576:  vextracti128 $1, %ymm0, %xmm3 
# | next:677'0                                  {   search range start (exclusive)
# | next:677'1                                      error: no match found in search range
# |           577:  vpextrq $1, %xmm2, %rax 
# |           578:  vpextrq $1, %xmm3, %rcx 
# |           579:  vmovq %xmm2, %rsi 
# |           580:  vmovq %xmm3, %rdx 
# |           581:  pextq %rax, %rcx, %rax 
# |           582:  pextq %rsi, %rdx, %rcx 
# |           583:  vpextrq $1, %xmm0, %rdx 
# |           584:  vmovq %rax, %xmm2 
# |           585:  vpextrq $1, %xmm1, %rax 
# | next:677'2      ?                         possible intended match
# |           586:  vmovq %rcx, %xmm3 
# |           587:  vmovq %xmm0, %rcx 
# |           588:  pextq %rax, %rdx, %rax 
# |           589:  vmovq %xmm1, %rdx 
# |           590:  vpunpcklqdq %xmm2, %xmm3, %xmm2 # xmm2 = xmm3[0],xmm2[0] 
# |             .
# |             .
# |             .
# |           595:  vinserti128 $1, %xmm2, %ymm0, %ymm0 
# |           596:  retq 
# |           597: .Lfunc_end7: 
# |           598:  .size pext_v4i64_minsize, .Lfunc_end7-pext_v4i64_minsize 
# |           599:  # -- End function 
# |           600:  .section ".note.GNU-stack","", at progbits 
# | next:677'3                                              } search range end (exclusive)
# | >>>>>>
# `-----------------------------
# error: command failed with exit status: 1

--

```
</details>

If these failures are unrelated to your changes (for example tests are broken or flaky at HEAD), please open an issue at https://github.com/llvm/llvm-project/issues and add the `infrastructure` label.

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


More information about the llvm-commits mailing list