tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: [RFC] Design considerations for XSAVE Extended Area getters/setters



On 28.05.2019 18:34, Michał Górny wrote:
> There is no difference in internal layout or logic between b. and c.
> In either case, we need to perform XSAVE, process it and copy the data
> into internal structure.  The only difference is that in b. we handle it
> all in one request, and in c. we do three requests copying different
> parts of XSAVE to three different buffers.
> 

I see. So (b) and (c) are the same except that XSAVE is a struct of a
dynamic size with normalized registers instead of explicit AVX, AVX512
calls.

I'm in favor of (c).

In the past I tried to normalize debug registers in the kernel (I know,
different thing to FPU), but it didn't work well. Instead of making it
safer and easier, it created x86 UB that was difficult to deal with in
the kernel space. It's just easier to just handle such things in
userland and export raw register sets as they are.

Attachment: signature.asc
Description: OpenPGP digital signature



Home | Main Index | Thread Index | Old Index