Re: [PATCH v1] x86/fpu: Remove opmask state from avx512_timestamp check

From: Borislav Petkov
Date: Thu Oct 14 2021 - 04:28:05 EST


On Wed, Oct 13, 2021 at 05:36:14PM -0500, Noah Goldstein wrote:
> Ping2

Why?

The original patch which added this abomination:

2f7726f95557 ("x86/fpu: Track AVX-512 usage of tasks")

says already:

the tracking mechanism is imprecise and can theoretically miss AVX-512
usage during context switch. But it has been measured to be precise
enough to be useful under real-world workloads like tensorflow and
linpack.

If higher precision is required, suggest user space tools to use the
PMU-based mechanisms in combination.

and as you've noticed, the high 16 regs would cause a false positive
too.

So what is the actual real-life use case for this?

--
Regards/Gruss,
Boris.

https://people.kernel.org/tglx/notes-about-netiquette