feature. See also
. The project being documented here (as the example) is the Zig library itself.
argon2.processBlocksAsync
fn processBlocksAsync(
blocks: *Blocks,
time: u32,
memory: u32,
threads: u24,
mode: Mode,
lanes: u32,
segments: u32,
io: Io,
) Io.Cancelable!void
File
Code
fn processBlocksAsync(
blocks: *Blocks,
time: u32,
memory: u32,
threads: u24,
mode: Mode,
lanes: u32,
segments: u32,
io: Io,
) Io.Cancelable!void {
var n: u32 = 0;
while (n < time) : (n += 1) {
var slice: u32 = 0;
while (slice < sync_points) : (slice += 1) {
var group: Io.Group = .init;
defer group.cancel(io);
var lane: u24 = 0;
while (lane < threads) : (lane += 1) {
group.async(io, processSegment, .{
blocks, time, memory, threads, mode, lanes, segments, n, slice, lane,
});
}
try group.await(io);
}
}
}