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

current

Public Function
std.debug.cpu_context.Alpha.current
pub inline fn current() Alpha

File

debug/cpu_context.zig:318
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
    pub inline fn current() Alpha {
        var ctx: Alpha = undefined;
        asm volatile (
            \\ stq $0 , 0x000($0)
            \\ stq $1 , 0x008($0)
            \\ stq $2 , 0x010($0)
            \\ stq $3 , 0x018($0)
            \\ stq $4 , 0x020($0)
            \\ stq $5 , 0x028($0)
            \\ stq $6 , 0x030($0)
            \\ stq $7 , 0x038($0)
            \\ stq $8 , 0x040($0)
            \\ stq $9 , 0x048($0)
            \\ stq $10, 0x050($0)
            \\ stq $11, 0x058($0)
            \\ stq $12, 0x060($0)
            \\ stq $13, 0x068($0)
            \\ stq $14, 0x070($0)
            \\ stq $15, 0x078($0)
            \\ stq $16, 0x080($0)
            \\ stq $17, 0x088($0)
            \\ stq $18, 0x090($0)
            \\ stq $19, 0x098($0)
            \\ stq $20, 0x0a0($0)
            \\ stq $21, 0x0a8($0)
            \\ stq $22, 0x0b0($0)
            \\ stq $23, 0x0b8($0)
            \\ stq $24, 0x0c0($0)
            \\ stq $25, 0x0c8($0)
            \\ stq $26, 0x0d0($0)
            \\ stq $27, 0x0d8($0)
            \\ stq $28, 0x0e0($0)
            \\ stq $29, 0x0e8($0)
            \\ stq $30, 0x0f0($0)
            \\ stq $31, 0x0f8($0)
            \\
            \\ br $1, 1f
            \\1:
            \\ stq $1, 0x100($0)
            :
            : [ctx] "{$0}" (&ctx),
            : .{ .r1 = true, .memory = true });
        return ctx;
    }