<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/109186>109186</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
-mvzeroupper
</td>
</tr>
<tr>
<th>Labels</th>
<td>
new issue
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
fbarchard
</td>
</tr>
</table>
<pre>
In XNNPack we have a mix of SSE2 and AVX2 code. Is _mm256_zeroupper() still required in all avx and avx512 code?
In this PR vzeroupper is automatically added. Nov 2019... clang 9.01
https://reviews.llvm.org/D69786
I found 7 microkernels in XNNPack that do _mm256_zeroupper() and require it. I remove the call and run a perf stat on skylake
It shows no sse-avx-assists.
Disassembling one of the avx kernels, clang added the vzeroupper.
But in godbolt, a simple avx function does not generate a vzeroupper?
https://godbolt.org/z/5E4KKc6Kv
I was wanting to test different compilers / versions to see which compilers require explicite _mm256_zeroupper()
Is this a bug?
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJx0U81u2zgQfhrqMrAg0bZiHXRINxUQBAiKLbDorRiRI4sbitRyKNnp0y8oq0lToBfpwJlvvp8ZZDZnR9SI4ydxfMhwjoMPTd9hUAMGnXVevzaPDr49P39B9QIXggEXAoTRXMH38PXrZwnoNNz_802C8ppyeGT4Po7yWH3_QcHP00RByJOQNXA01kKg_2YTSINxgNYCLtcVApfrsbyBiH0rigdR3N--jw7iYBi-_A3LGyYYBpyjHzEahda-AmpNOgd49gvIoqzzPAdl0Z2hzovyBjXEOLHY3wvZCtkGWgxdOLd2GXMfzkK2D1V9d6o-TIfez07DHYxGBf9CwZHlxP6nLXHACNr_SXYSt4kGE3OARwg0-oUgDgRq9SCVzA4QJgo9cMQI3gG_vFp8oY1HBB78hcF5YKYdLtddSpAj57eKB8PITGNnjTuDd5QiSjOSxRtvIf_aTFntWp_fTc1_Ff5pjknl2evO25gaEdiMk70B9rNT0XgH2lMiFeFMjgLGtB_vkG9ZfrR-Q91c_yFke_x8eHpS1dPy0fwLMlzQxSQpeojEEbTpewrkIig_TsZSYBCyhYUCG-84FTIRXAajhl9qfqZA18kaZSL9KbJtON_2DqGbz2LfZrrZ63pfY0ZNeSer6lRXp0M2NNXdqesl9RXJSiIdyyNWqi_3dadVr6nITCMLeSjq8iSLopSHvOolUnk4VDXuUVZaHAoa0di3VcwM80xNmXqqzGJHltc7ldLRBdZXIWU629Ckpl03n1kcCrsuxBtMNNFSsxvfA8nmYJvfwjBxmLtc-VHINrVuv90U_L-kopDtOpCFbDdGSyP_DwAA__9z8WQL">