[Lldb-commits] [PATCH] D117928: [lldb] Disable tests for x86 that uses write command on XMM registers

Luís Ferreira via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Mon Jan 24 20:56:27 PST 2022


ljmf00 added a comment.

In D117928#3265583 <https://reviews.llvm.org/D117928#3265583>, @mgorny wrote:

> Could you try replacing the new function with the old one and seeing if that helps? Or alternatively, trying to build a kernel from the commit just before that change and with that change.

I can reproduce with the introduced change and by removing the `memset` call, I can write to the registers. I submitted a patch to the kernel mailing list. See the kernel bug tracker for discussion. I talked a bit about the flow of LLDB to discover XSAVE and FXSAVE, although correct me there if I'm wrong.

In D117928#3266895 <https://reviews.llvm.org/D117928#3266895>, @labath wrote:

> If you want, I can try to create a patch for this, though it might take me a couple of days to get around to it.

I'm probably not getting the full picture but my idea on this is: if we propose this change due to this specific kernel regression is not worth it, although we should consider it if there is any other benefit on using `PTRACE_POKEUSER`.

In D117928#3267103 <https://reviews.llvm.org/D117928#3267103>, @mgorny wrote:

> To explain a bit, `PT_SETXMMREGS` exists because originally `PT_SETFPREGS` used FSAVE format on i386, and this format didn't support setting XMM registers. Newer CPUs support FXSAVE instead, and this is exposed via `PT_SETFPREGS` on amd64 and `PT_SETXMMREGS` on i386.

Ok, makes sense.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D117928/new/

https://reviews.llvm.org/D117928



More information about the lldb-commits mailing list