This is an archive of the discontinued LLVM Phabricator instance.

[lldb] [lit] Add tests for reading new x86_64 registers
ClosedPublic

Authored by mgorny on Apr 24 2019, 8:51 AM.

Details

Diff Detail

Repository
rL LLVM

Event Timeline

mgorny created this revision.Apr 24 2019, 8:51 AM
Herald added a project: Restricted Project. · View Herald TranscriptApr 24 2019, 8:51 AM
Herald added a subscriber: teemperor. · View Herald Transcript
mgorny updated this revision to Diff 196502.Apr 24 2019, 12:58 PM

Fixed unnecessary array in xmm_t decls.

labath accepted this revision.Apr 25 2019, 8:52 AM
labath added inline comments.
lldb/lit/Register/Inputs/x86-64-read.cpp
8 ↗(On Diff #196502)

what do you think about including r0-r7 too? They're of different sizes on x86 vs x86_64, so I don't think we'll be able to have a single test which would work on both arches.

This revision is now accepted and ready to land.Apr 25 2019, 8:52 AM
mgorny added inline comments.Apr 25 2019, 9:12 AM
lldb/lit/Register/Inputs/x86-64-read.cpp
8 ↗(On Diff #196502)

Do you mean RAX, RBX, etc.? Yeah, I suppose I can do that.

labath added inline comments.Apr 25 2019, 9:34 AM
lldb/lit/Register/Inputs/x86-64-read.cpp
8 ↗(On Diff #196502)

Yep, those. %rip might be interesting too. I mean, it's so fundamental that we're bound to notice if reading it ever breaks, but it might be nice to have an test which clearly indicates what the problem is. You'll probably have a hard time setting it to a known value, but you might be able to test it via relationship with some other registers (e.g. %rax == (%rip << 32) & (%rip >> 32)).

This revision was automatically updated to reflect the committed changes.
Herald added a project: Restricted Project. · View Herald TranscriptApr 25 2019, 10:43 AM