ASM Editor home Projects Docs Learn Blog
Donate
Star on github
M68K Addressing modes Condition codes Shift directions Trap tasks Synth Exceptions Directives Assembler features Complete documentation

abcdaddaddaaddiaddqaddxandandiasdaslasrbccbchgbclrbcsbeqbfchgbfclrbfextsbfextubfffobfinsbfsetbftstbgebgtbhibhsbkptblebloblsbltbmibnebplbrabsetbsrbtstbvcbvscascas2chkchk2clrcmpcmp2cmpacmpicmpmdbccdbcsdbeqdbfdbgedbgtdbhidbhsdbledblodblsdbltdbmidbnedbpldbradbtdbvcdbvsdivsdivsldivudivuleoreoriexgextextbillegaljmpjsrlealinklsdlsllsrmovemoveamovecmovemmovepmoveqmovesmulsmulunbcdnegnegxnopnotororipackpearesetrodrolrorroxdroxlroxrrtdrtertrrtssbcdsccscsseqsfsgesgtshishsslesloslssltsmisnesplststopsubsubasubisubqsubxsvcsvsswaptastraptrapcctrapcstrapeqtrapftrapgetrapgttraphitraphstrapletraplotraplstraplttrapmitrapnetrappltrapttrapvtrapvctrapvststunlkunpk
Create your first project

unlk

Unlink

Loads a7 from the address register, then pops a long from the stack into that register.

Used in
  • bsr, rts, link and unlkM68K assembly
  • Stack arguments and a stack frameM68K assembly
  • Recursion: factorial and FibonacciM68K assembly
XNZVC –––––
  • Leaves every flag unchanged

Forms

  • unlk

Operands

An
An address register, a0 to a7; sp is another name for a7. More
* --- Used with link to tear down a stack frame ---
link a6, #-8
move.l #$1234, -4(a6)
move.l #$5678, -8(a6)
unlk a6 ; sp = a6, a6 = (sp)+1
2
3
4
5