Category:68000 Assembly: Difference between revisions

Content added Content deleted
No edit summary
Line 177: Line 177:
<lang 68000devpac>MyString: DC.B "HELLO WORLD 12345678900000",0
<lang 68000devpac>MyString: DC.B "HELLO WORLD 12345678900000",0
EVEN ;some assemblers require this to be on its own line</lang>
EVEN ;some assemblers require this to be on its own line</lang>
==Subroutines==

Subroutines work exactly the same as they do in [[6502 Assembly]]. Even the commands are the same; <code>JSR</code> and <code>RTS</code>. The only difference is that return spoofing doesn't require the return address to be decremented by 1. The 68000 also adds <code>BSR</code> for nearby subroutines. These still need to end in an <code>RTS</code> just the same, but saves CPU cycles compared to a <code>JSR</code>.
==Citations==
==Citations==
#'Akuyou', Keith. <i>Learn Multiplatform Assembly Programming with Chibiakumas!</i> Las Vegas, NV. Self-published, 05 April 2021.
#'Akuyou', Keith. <i>Learn Multiplatform Assembly Programming with Chibiakumas!</i> Las Vegas, NV. Self-published, 05 April 2021.