Skip to content

Commit d8268fa

Browse files
committed
std.debug: fix FP-based unwinding on powerpc64
This just needs to do the same thing as powerpc64le. Note that the saved LR is at the same position in both ELF v1 and v2.
1 parent 07c3f9e commit d8268fa

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/std/debug.zig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -951,7 +951,7 @@ const StackIterator = union(enum) {
951951

952952
/// Offset of the saved return address wrt the frame pointer.
953953
const ra_offset = off: {
954-
if (native_arch == .powerpc64le) break :off 2 * @sizeOf(usize);
954+
if (native_arch.isPowerPC64()) break :off 2 * @sizeOf(usize);
955955
// On s390x, r14 is the link register and we need to grab it from its customary slot in the
956956
// register save area (ELF ABI s390x Supplement §1.2.2.2).
957957
if (native_arch == .s390x) break :off 14 * @sizeOf(usize);

0 commit comments

Comments
 (0)