Zig 0.17.0-dev (Split by item)

Shortcut keys
?
Show these tips
S
Focus search field
Esc
Clear focus & close tips
U
Jump to source code
↑
Move up in search results
↓
Move down in search results
↵
Go to active search result
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 standard library. Public Function

futex2_wake

Public Function
std.os.linux.futex2_wake
pub fn futex2_wake(
    /// Futex to wake
    uaddr: *const anyopaque,
    /// Bitmask to match against waiters.
    mask: usize,
    /// Maximum number of waiters on the futex to wake.
    nr_wake: i32,
    flags: FUTEX2_FLAGS,
) usize

Wake (subset of) waiters on given futex. Identical to the traditional FUTEX.FUTEX_WAKE_BITSET op, except it is part of the futex2 family of calls.

Requires at least kernel v6.7.

Params

  • uaddr: *const anyopaque

    Futex to wake

  • mask: usize

    Bitmask to match against waiters.

  • nr_wake: i32

    Maximum number of waiters on the futex to wake.

  • flags: FUTEX2_FLAGS

File

os/linux.zig:987
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
pub fn futex2_wake(
    /// Futex to wake
    uaddr: *const anyopaque,
    /// Bitmask to match against waiters.
    mask: usize,
    /// Maximum number of waiters on the futex to wake.
    nr_wake: i32,
    flags: FUTEX2_FLAGS,
) usize {
    return syscall4(
        .futex_wake,
        @intFromPtr(uaddr),
        mask,
        @as(u32, @bitCast(nr_wake)),
        @as(u32, @bitCast(flags)),
    );
}