HomeFreeBSD

dtrace: dtrace_getpcstack() tweaks for riscv

Description

dtrace: dtrace_getpcstack() tweaks for riscv

Backtraces for fbt probes are missing the caller's frame. Despite what
the inherited comment claims, we do need to insert this manually on
riscv. In fbt_invop(), set cpu_dtrace_caller to be the return address,
not addr.

We should not increment aframes within this function, since we begin the
main loop by unwinding past the current frame.

Plus some very small comment/style tweaks.

MFC after: 1 week
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D37661

Details

Provenance
mhorneAuthored on Jan 11 2023, 6:06 PM
Differential Revision
D37661: dtrace: dtrace_getpcstack() tweaks for riscv
Parents
rG756a67e15e01: dtrace: kill mips definitions in profile provider
Branches
Unknown
Tags
Unknown