ajhahn.de
← Flash
Flash 17 lines
// hello — the smallest Flash program: write a line, then exit.
//
// The first spike target: lowers to a freestanding AArch64 ELF that the FlashOS
// kernel loads at EL0, proving the whole pipeline before a single coreutil is
// ported.

use flibc

link "flibc_start"
link "flibc_mem"

export fn main(_ usize, _ argv) noreturn {
    msg := "hello from flash\n"
    _ = flibc.sys.write_fd(1, msg.ptr, msg.len)
    flibc.exit()
}