Add compilation method for IR-JUMP

This commit is contained in:
John Lorentzson 2025-07-03 16:56:10 +02:00
parent f9d8ad13d0
commit 3876801960

View file

@ -183,6 +183,14 @@
(emit-asm-instruction :opcode #x20 :operand (callee inst) :byte-length 3)
(emit-store-result (output inst)))
(defmethod compile-ir ((inst ir-jump))
(unless (eql (next (iblock inst))
(first (destinations inst)))
(emit-asm-instruction :opcode #x4C
:operand (first (destinations inst))
:byte-length 3))
(setf *last-instruction* '(:jump)))
(defmethod compile-ir ((inst ir-test-equal))
(emit-load-data (first (inputs inst)))
(if (eql (strategy (allocation-details (second (inputs inst))))