[Lldb-commits] [PATCH] D89193: [lldb] [Process/FreeBSDRemote] Support YMM reg via PT_*XSTATE

Michał Górny via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Tue Oct 13 09:58:51 PDT 2020


mgorny added inline comments.


================
Comment at: lldb/source/Plugins/Process/FreeBSDRemote/NativeRegisterContextFreeBSD_x86_64.cpp:448-449
+
+    assert(info.xsave_mask & XFEATURE_ENABLED_X87);
+    assert(info.xsave_mask & XFEATURE_ENABLED_SSE);
+
----------------
mgorny wrote:
> emaste wrote:
> > I wonder if these should be an error rather than assertion?
> I suppose the question is if they ever happen in real use. If they do, we should probably handle them gracefully. Otherwise, assertion should be sufficient.
I can actually answer the first question myself. According to Intel's manual, it is impossible to disable x87 bit. IIRC attempt to unset it on XCR0 will raise some fault.

The second question is basically whether under any circumstances can FreeBSD kernel disable SSE on XCR0 (this code is only used on systems supporting XSAVE).


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

https://reviews.llvm.org/D89193



More information about the lldb-commits mailing list