Primality by trial division: Difference between revisions
Content added Content deleted
Puppydrum64 (talk | contribs) |
Puppydrum64 (talk | contribs) |
||
Line 149: | Line 149: | ||
notPrime: |
notPrime: |
||
MOVE.L #0,D0 |
MOVE.L #0,D0 ;return false |
||
MOVEM.L (SP)+,D1-D4 ;pop D1-D4 |
MOVEM.L (SP)+,D1-D4 ;pop D1-D4 |
||
RTS |
RTS |
||
wasPrime: |
wasPrime: |
||
MOVE.L #1,D0 |
MOVE.L #1,D0 ;return true |
||
MOVEM.L (SP)+,D1-D4 ;pop D1-D4 |
MOVEM.L (SP)+,D1-D4 ;pop D1-D4 |
||
RTS |
RTS |
||
;end of program |
;end of program</lang> |
||
=={{header|AArch64 Assembly}}== |
=={{header|AArch64 Assembly}}== |