mirror of
https://github.com/ziglang/zig.git
synced 2026-02-13 04:48:20 +00:00
start: Align the stack on s390x just in case.
The kernel does this as required, but we cannot trust dynamic linkers to do it.
This commit is contained in:
parent
52653ec82b
commit
ce81525f3f
@ -373,8 +373,9 @@ fn _start() callconv(.Naked) noreturn {
|
||||
,
|
||||
.s390x =>
|
||||
// Set up the stack frame (register save area and cleared back-chain slot).
|
||||
// Note: Stack pointer is guaranteed by ABI to be 8-byte aligned as required.
|
||||
\\ lgr %r2, %r15
|
||||
\\ lghi %r0, -16
|
||||
\\ ngr %r15, %r0
|
||||
\\ aghi %r15, -160
|
||||
\\ lghi %r0, 0
|
||||
\\ stg %r0, 0(%r15)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user