code wiki / (root) / smoke_asm_d9.nx

smoke_asm_d9.nx source

↩ module page · 7 lines · 266 B

1// Dump byte at position 63 of the literal (where strlen stops). 2import "syscalls.nx" 3 4func main() -> i64 { 5 let s: *u8 = ".text\n.globl main\nmain:\naddi sp, sp, -16\nsd ra, 8(sp)\nli a0, 30\nret\n" 6 return __syscall(93, s[63] & 0xFF, 0, 0, 0, 0, 0) 7}