The Jit normally issues vzeroupper commands at entry and exit of methods, however when when mixing Avx and Sse code in the same method it is helpful to manually issue vzeroupper at the transitions:
Proposed api
public partial abstract class Avx : Sse42
{
/// <summary>
/// void _mm256_zeroupper (void)
/// VZEROUPPER
/// </summary>
public static void ZeroUpper();
/// <summary>
/// void _mm256_zeroall (void)
/// VZEROALL
/// </summary>
public static void ZeroAll();
}
Also added vzeroall for discussion.
Use case: dotnet/coreclr#22187 (comment)
/cc @CarolEidt @fiigii @tannergooding @jkotas
The Jit normally issues
vzerouppercommands at entry and exit of methods, however when when mixing Avx and Sse code in the same method it is helpful to manually issuevzeroupperat the transitions:Proposed api
Also added
vzeroallfor discussion.Use case: dotnet/coreclr#22187 (comment)
/cc @CarolEidt @fiigii @tannergooding @jkotas