Revert "remove plan9 test coverage": Plan9 now works :^)

This reverts commit 67db2b85b771d8b0f9d765922951c31fce9c8cc2.
This commit is contained in:
Jacob G-W 2022-10-05 20:54:02 -04:00
parent 6cba18fe60
commit c6fb798740
3 changed files with 43 additions and 0 deletions

View File

@ -0,0 +1,5 @@
pub fn main() void {}
// run
// target=x86_64-plan9,aarch64-plan9
//

View File

@ -0,0 +1,28 @@
pub fn main() void {
const str = "Hello World!\n";
asm volatile (
\\push $0
\\push %%r10
\\push %%r11
\\push $1
\\push $0
\\syscall
\\pop %%r11
\\pop %%r11
\\pop %%r11
\\pop %%r11
\\pop %%r11
:
// pwrite
: [syscall_number] "{rbp}" (51),
[hey] "{r11}" (@ptrToInt(str)),
[strlen] "{r10}" (str.len),
: "rcx", "rbp", "r11", "memory"
);
}
// run
// target=x86_64-plan9
//
// Hello World
//

View File

@ -0,0 +1,10 @@
const std = @import("std");
pub fn main() void {
const str = "Hello World!\n";
_ = std.os.plan9.pwrite(1, str, str.len, 0);
}
// run
//
// Hello World
//