diff --git a/lib/std/start.zig b/lib/std/start.zig index 081e9d44f0..ff524d5d64 100644 --- a/lib/std/start.zig +++ b/lib/std/start.zig @@ -300,6 +300,12 @@ fn _start() callconv(.Naked) noreturn { \\ and sp, #-16 \\ b %[posixCallMainAndExit] , + .loongarch64 => + \\ move $fp, $zero + \\ move $a0, $sp + \\ bstrins.d $sp, $zero, 3, 0 + \\ b %[posixCallMainAndExit] + , .riscv64 => \\ li s0, 0 \\ li ra, 0