<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/114360>114360</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
Wrong result for _BitInt bitwise & testcase
</td>
</tr>
<tr>
<th>Labels</th>
<td>
new issue
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
mikaelholmen
</td>
</tr>
</table>
<pre>
llvm commit: 6effab990c5c1b
Reproducer:
```
clang bbi-100697.c -O2 -std=c23
./a.out
```
Result:
```
Fail!
```
This starts happening with https://github.com/llvm/llvm-project/commit/1833d418a04123916c1dbeb0c41c8bc7d06b779b
Before that commit we got
```
Pass!
```
which is the expected result.
I originally reported this in https://github.com/llvm/llvm-project/pull/107461#issuecomment-2446969736 but @alexey-bataev did some analysis in https://github.com/llvm/llvm-project/pull/107461#issuecomment-2448053507 suggesting that the error is somewhere in X86 Codegen rather than in SLP vectorizer.
As I wrote in the original report the input was originally part of a much larger test so I've reduced it a lot but unfortunately it's still quite large (and ugly).
[bbi-100697.c.gz](https://github.com/user-attachments/files/17582314/bbi-100697.c.gz)
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJy0lEuLIzcQxz-NfCls9OjnoQ8zGQwDgSybQHILkrrcrURudaSSvd5PH9R2yG6YDcxhwVi0Hn_V_1el0im5aUEcWP3M6pedzjSHOJzdnxr9HPwZl50J423w_nIGG85nR0w9QYOnkzZ9z21thWH8hfGnj7jGMGaLkamn-xRr-OO3fVqvlwmMcXvBedO3Bwv7nyTsE41MvVip7tsOTB71IWR6U-QjpuzpW1cctfNMijfXfpldgkQ6UoJZrysubpng6miGmWhNRVMemTxOjuZsDjacmTwW549hv8bwB1pi8vhAIY-iU2qsRKd5JaTqRWPFaNBwWwnbGduOvDFt2z8YPeMpRASaNT1owhVhCm9b_aBT-paZ6-zsDC4BzQj4aUVLOELc4BweJ7b_VwjRTW7R3t8g4hpi2UiFhVveb3zN3hfbvK0awaRyKWUsVnChvayqpm_6VjVgMgGruPb4CW97o0njBUY3QgpnBL1of0vfKYSO16rmLaQ8TZioJHkDvpGKMcSCrYRxnTFiCeG3roEfwogTLhA1zRjLiaUs_fzjB7igpRDdZ4xfkX1K8ArXGGjTKOr_kH5w3ubcsmaCq05f5mHVkSCcQMM52xm8jlO5ExNBCvDKZHtBiFhe0wiOQIMPtDHNyylEyosm9DcoJdiWonbew1_ZEd61gMlOLyPkyd-Y7L8Km9XPXz7Bw_SZ1S9Mdv-Th5ww7jWRtnOBnJg8npzHMoq27qQSFZPH_6rK_n7hbhzU2Kte73AQreKqlrxtdvPQ95W11oy27rtOCGUqUxmuTwKbTndds3OD5LISXAleSyGagxjbRiorsLZ1ZxvDKo5n7fyhlMghxGm3FcMgRKUavvPaoE9bc5NywStsq0zK0uvi1tT2Jk-JVdy7ROlfGXLkcfg1hmV6PCo4hQi_Pzt6XQiMo6tLBXOzZc3qhLsc_fDuYt4i2kDeQ74M8u8AAAD__3x9vbk">