Begin work on pseudo mnemonics in the checker

This commit is contained in:
gingerBill
2026-08-20 19:12:44 +01:00
parent cfb8a109b6
commit 7a7bfea0bd
8 changed files with 315 additions and 96 deletions

View File

@@ -2805,8 +2805,11 @@ gb_internal Ast *parse_asm_template(AstFile *f) {
asm_instructions = slice_from_array(instructions);
}
if (build_context.metrics.arch != TargetArch_amd64) {
syntax_error(token, "asm templates are currently only supported on -target:amd64");
if (build_context.metrics.arch == TargetArch_amd64 ||
build_context.metrics.arch == TargetArch_riscv64) {
// okay
} else {
syntax_error(token, "asm templates are currently only supported on -target:*_amd64 or -target:*_riscv64");
}
Ast *asm_template = alloc_ast_node(f, Ast_AsmTemplate);