Skip to content

Commit

Permalink
Merge pull request #21608 from mikdusan/ppc64
Browse files Browse the repository at this point in the history
ppc64: get further along into system bootstrap
  • Loading branch information
alexrp authored Oct 6, 2024
2 parents ece265b + 665d015 commit 148b5b4
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
10 changes: 5 additions & 5 deletions lib/std/os/linux/powerpc64.zig
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ pub fn syscall2(number: SYS, arg1: usize, arg2: usize) usize {
: [number] "{r0}" (@intFromEnum(number)),
[arg1] "{r3}" (arg1),
[arg2] "{r4}" (arg2),
: "memory", "cr0", "r4", "r5", "r6", "r7", "r8", "r9", "r10", "r11", "r12"
: "memory", "cr0", "r5", "r6", "r7", "r8", "r9", "r10", "r11", "r12"
);
}

Expand All @@ -63,7 +63,7 @@ pub fn syscall3(number: SYS, arg1: usize, arg2: usize, arg3: usize) usize {
[arg1] "{r3}" (arg1),
[arg2] "{r4}" (arg2),
[arg3] "{r5}" (arg3),
: "memory", "cr0", "r4", "r5", "r6", "r7", "r8", "r9", "r10", "r11", "r12"
: "memory", "cr0", "r6", "r7", "r8", "r9", "r10", "r11", "r12"
);
}

Expand All @@ -79,7 +79,7 @@ pub fn syscall4(number: SYS, arg1: usize, arg2: usize, arg3: usize, arg4: usize)
[arg2] "{r4}" (arg2),
[arg3] "{r5}" (arg3),
[arg4] "{r6}" (arg4),
: "memory", "cr0", "r4", "r5", "r6", "r7", "r8", "r9", "r10", "r11", "r12"
: "memory", "cr0", "r7", "r8", "r9", "r10", "r11", "r12"
);
}

Expand All @@ -96,7 +96,7 @@ pub fn syscall5(number: SYS, arg1: usize, arg2: usize, arg3: usize, arg4: usize,
[arg3] "{r5}" (arg3),
[arg4] "{r6}" (arg4),
[arg5] "{r7}" (arg5),
: "memory", "cr0", "r4", "r5", "r6", "r7", "r8", "r9", "r10", "r11", "r12"
: "memory", "cr0", "r8", "r9", "r10", "r11", "r12"
);
}

Expand All @@ -122,7 +122,7 @@ pub fn syscall6(
[arg4] "{r6}" (arg4),
[arg5] "{r7}" (arg5),
[arg6] "{r8}" (arg6),
: "memory", "cr0", "r4", "r5", "r6", "r7", "r8", "r9", "r10", "r11", "r12"
: "memory", "cr0", "r9", "r10", "r11", "r12"
);
}

Expand Down
1 change: 1 addition & 0 deletions lib/std/start.zig
Original file line number Diff line number Diff line change
Expand Up @@ -391,6 +391,7 @@ fn _start() callconv(.Naked) noreturn {
\\ stdu 0, -32(1)
\\ mtlr 0
\\ b %[posixCallMainAndExit]
\\ nop
,
.s390x =>
// Set up the stack frame (register save area and cleared back-chain slot).
Expand Down

0 comments on commit 148b5b4

Please sign in to comment.