GDB / AArch64 / MacOS
Tom Tromey
tom@tromey.com
Sun Jul 23 19:51:50 GMT 2023
Andrew> Maybe I could start with the AArch64/BSD target, do you think? The
Andrew> differences would be the way that args are passed between functions
Andrew> and stack layouts, I guess.
There's two parts to a gdb port like this.
One is the "tdep" code. This holds target- and arch-dependent
information. This is where you'd put things like knowledge of the ABI.
There's also the "nat" code. This is host dependent code that knows how
to do low-level debugging. E.g., linux-nat handles calling ptrace.
The split is done so cross debugging can work -- the tdep code can be
built anywhere and be used for remote debugging. These days the nat
code tends to be shared somewhat with gdbserver, though I don't think
that was ever ported to Darwin.
For a new Darwin port you will probably need both of these.
Tom
More information about the Gdb
mailing list