Something went wrong. Try again.
🌱 A minimal programming language and compiler. git.urbach.dev/cli/q
high-performance programming-language compiler
Something went wrong. Try again.
123456789101112131415161718192021222324252627package codegen
import ( "git.urbach.dev/cli/q/src/asm" "git.urbach.dev/cli/q/src/cpu")
// moveCallResult moves the result from the call output register to the destination.func (f *Function) moveCallResult(step *Step, source cpu.Register) { destination := step.Register
if destination == -1 || destination == source { return }
isSpilled := f.isSpilled(destination)
if isSpilled { f.storeSpill(step, source) return }
f.Assembler.Append(&asm.Move{ Destination: destination, Source: source, })}