Zig 0.17.0-dev (Split by item)

This is an example of documentation generated by ZigDoc, an alternative to Zig's built-in Auto Doc feature. See also examples in other modes/formats. The project being documented here (as the example) is the Zig library itself.

__chkstk

stack_probe.__chkstk
pub fn __chkstk() callconv(.naked) void

File

lib/compiler_rt/stack_probe.zig:249

Code

pub fn __chkstk() callconv(.naked) void {
    @setRuntimeSafety(false);
    if (arch == .thumb or arch == .aarch64) {
        @call(.always_inline, win_probe_stack_only, .{});
    } else switch (arch) {
        .x86 => @call(.always_inline, win_probe_stack_adjust_sp, .{}),
        .x86_64 => @call(.always_inline, win_probe_stack_only, .{}),
        else => unreachable,
    }
}