;30-byte lzss by Zerkman^Sector1 GAS lea pkgbeg(pc), a0 | r lea out(pc), a1 | w lea pkgend(pc), a2 | end next: move.b (a0)+, d0 ext d0 bpl.s raw repeat: move d0, d1 and #0x3f, d0 | size btst #6, d1 | test bit 6 beq.s short move.b (a0)+, d1 | offset bra.s copy short: or #0xfff0, d1 | offset lsr #4, d0 | size copy: addq #3, d0 lea (a1, d1.w), a3 | w+offset loop: move.b (a3)+, (a1)+ dbra d0, loop bra.s test raw: move.b (a0)+, (a1)+ dbra d0, raw test: cmp.l a2, a0 bne.s next bra out