1# sh testcase for mac.l 2# mach: all 3# as(sh): -defsym sim_cpu=0 4# as(shdsp): -defsym sim_cpu=1 -dsp 5 6 .include "testutils.inc" 7 8 start 9 # force S-bit clear 10 clrs 11 12init: 13 # Prime {MACL, MACH} to #1. 14 mov #1, r0 15 dmulu.l r0, r0 16 17 # Set up addresses. 18 mov.l pfour00, r0 ! 85 19 mov.l pfour12, r1 ! 17 20 21test: 22 mac.l @r0+, @r1+ 23 24check: 25 # Check result. 26 assert_sreg 0, mach 27 assert_sreg 85*17+1, macl 28 29 # Ensure post-increment occurred. 30 assertreg0 four00+4 31 assertreg four12+4, r1 32 33doubleinc: 34 mov.l pfour00, r0 35 mac.l @r0+, @r0+ 36 assertreg0 four00+8 37 38 39 pass 40 exit 0 41 42 .align 1 43four00: 44 .long 85 45 .long 2 46four12: 47 .long 17 48 .long 3 49 50 .align 2 51pfour00: 52 .long four00 53pfour12: 54 .long four12 55