Refactored assembly compilation

This commit is contained in:
2025-04-06 20:37:26 +02:00
parent 543558a02b
commit cac2bad2fe
12 changed files with 900 additions and 857 deletions

View File

@ -27,13 +27,17 @@ func Finalize(a *asm.Assembler, dlls dll.List) ([]byte, []byte) {
switch config.TargetArch {
case config.ARM:
armc := armCompiler{compiler: &c}
for _, x := range a.Instructions {
c.ARM(x)
armc.Compile(x)
}
case config.X86:
x86c := x86Compiler{compiler: &c}
for _, x := range a.Instructions {
c.X86(x)
x86c.Compile(x)
}
}