Page MenuHomePhabricator

[lldb] [Process/NetBSD] Fix reading FIP/FDP registers

Authored by mgorny on Thu, Oct 1, 10:42 AM.



Fix reading FIP/FDP registers to correctly return segment and offset
parts. On amd64, this roughly matches the Linux behavior of splitting
the 64-bit FIP/FDP into two halves, and putting the higher 32 bits
into f*seg and lower into f*off. Well, actually we use only 16 bits
of higher half but the CPUs do not seem to handle more than that anyway.

Diff Detail

Event Timeline

mgorny requested review of this revision.Thu, Oct 1, 10:42 AM
mgorny created this revision.
labath accepted this revision.Fri, Oct 2, 12:04 AM

I'm assuming this is tested by D88583.

This revision is now accepted and ready to land.Fri, Oct 2, 12:04 AM

Yes. We also need to fix our kernel but it's no less broken than it was before.

krytarowski added inline comments.Fri, Oct 2, 10:31 AM

GetAsUInt32 above and GetAsUInt64 here?

mgorny updated this revision to Diff 295869.Fri, Oct 2, 10:48 AM
mgorny marked an inline comment as done.

Fix mistype.

krytarowski accepted this revision.Fri, Oct 2, 10:50 AM
This revision was automatically updated to reflect the committed changes.
Herald added a project: Restricted Project. · View Herald TranscriptSat, Oct 3, 10:55 AM