Skip to documentation
SLOP

tiny.simd.NextWithSkip

Reference tiny.simd NextWithSkip

Defined in autotune.

Called byCallsautotuneAutoTunetest sourcelib.simd.src.autotunetest: Highway next-with-skip retains ...test sourcelib.simd.src.autotunetest: Highway next-with-skip wraps an...private sourcelib.simd.src.autotune.LinkinitautotuneNextWithSkip
Static calls · unresolved targets: 0 · external targets: 0.

Source

Source: lib/simd/src/autotune.zig:193

zig
pub fn NextWithSkip(comptime capacity: usize) type {    comptime {        if (capacity == 0) @compileError("NextWithSkip requires positive capacity");        if (capacity >= Link.max_count) {            @compileError("NextWithSkip capacity exceeds packed index range");        }    }    return struct {        links: [capacity]Link = @splat(.{}),        count: usize = 0,        const Self = @This();        pub fn init(count: usize) Self {            std.debug.assert(count != 0);            std.debug.assert(count <= capacity);            var self = Self{};            self.count = count;            for (self.links[0..count], 0..) |*link, position| {                link.* = Link.init(position, count);            }            return self;        }        pub fn next(self: *const Self, position: usize) usize {            std.debug.assert(position < self.count);            std.debug.assert(!self.links[position].isRemoved());            return self.links[position].next();        }        pub fn skip(self: *Self, position: usize) void {            std.debug.assert(position < self.count);            std.debug.assert(!self.links[position].isRemoved());            const previous = self.links[position].previous();            const next_position = self.links[position].next();            if (previous == position or next_position == position) return;            self.links[next_position].setPrevious(previous);            self.links[previous].setNext(next_position);            self.links[position].remove();        }    };}

Source: lib/simd/src/root.zig:562

zig
pub const NextWithSkip = autotune.NextWithSkip;

Audit

Definitions1
Public names2
Members0
Version26.7.0
Revisiondaab053ee433