<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/152490>152490</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
[Headers][X86] Allow SSE2/AVX2/AVX512F/AVX512BW/AVX512DQ integer arithmetic intrinsics to be used in constexpr
</td>
</tr>
<tr>
<th>Labels</th>
<td>
new issue
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
RKSimon
</td>
</tr>
</table>
<pre>
All of these intrinsics wrap generic implementations which can already be used in constexpr
```
_mm_add_epi8 _mm_add_epi16 _mm_add_epi32 _mm_add_epi64
_mm_sub_epi8 _mm_sub_epi16 _mm_sub_epi32 _mm_sub_epi64
_mm_mullo_epi16 _mm_mullo_epi32
_mm256_add_epi8 _mm256_add_epi16 _mm256_add_epi32 _mm256_add_epi64
_mm256_sub_epi8 _mm256_sub_epi16 _mm256_sub_epi32 _mm256_sub_epi64
_mm256_mullo_epi16 _mm256_mullo_epi32
_mm512_add_epi8 _mm512_add_epi16 _mm512_add_epi32 _mm512_add_epi64
_mm512_sub_epi8 _mm512_sub_epi16 _mm512_sub_epi32 _mm512_sub_epi64
_mm512_mullo_epi16 _mm512_mullo_epi32
_mm_mullo_epi64 _mm256_mullo_epi64 _mm512_mullo_epi64
```
(ignore the AVX512 mask/maskz variants for now)
You can use https://github.com/llvm/llvm-project/pull/152296 for reference
</pre>
<img width="1" height="1" alt="" src="http://email.email.llvm.org/o/eJyUVE1v3CAQ_TX4groCvPjj4IOjrVWppzZSmp4ibI9tWgwW4GzTX1_5I1mc9lLJErxn3sxjgBHOyV4DFIjfIX6JxOwHY4uvn-_laHRUm_alKJXCpsN-AAdYam-ldrJx-GrFhHvQYGWD5TgpGEF74aXRDl8H2Qy4ERoLZUG0L7gGPDtosdS4Mdp5-DVZREqUkP0j5dM4Pom2fYJJZjgANAlRzEKUnHehm-ubcAe7cEe7cEdvwnFWygSr33DMFn_rIsaTg7MAb6qA2NIExGumhQpdBvgW5OA1IMIg7xwfqMA0p-xgOsCbMCC2fAHxmm-hQtMBvgU5mA6IMMg70wdqNX2ofXL-a2cbddCt8cMbhFgme20sLNcVlw-PnDI8CvcTsWoZfuNnYaXQ3uHOWKzNFbF8K9h3M6_3dXaAB-8nh-ISsQqxqpd-mOtTY0bEKqWeX4cPkzU_oPGIVdOsFGIV5YzlyRraQgcWdANRW8RtHucigoKm_MxTmpA0Goo85zxNaVt3JOYZSZOGpl2atKQlOaUJjWTBCOMkIymNCSH8xLsuzpsuhazmDY1TdCYwCqlOi5uTsX0knZuhoJydcxIpUYNy69NmTMMVr38RY8tLt8W6hXruHToTJZ13tzBeerX2hE8gWrAO8Qvid49ZgvgFl0qZK76__8gQq8qHx33gdC3WNrv79ja9fFmaBvRgsbDSDyP4pV_c-og3_-wN0WxV8d8HsW7RbUex1OC5YH8CAAD__7A4mQM">