1 # sh testcase for all mov.[bwl] instructions
3 # as(sh): -defsym sim_cpu=0
5 .include "testutils.inc"
8 _lsrc
: .long 0x55555555
9 _wsrc
: .long 0x55550000
10 _bsrc
: .long 0x55000000
20 movb_disp12_reg
: # Test 8-bit @(disp12,gr) -> gr
29 assertreg _bsrc-
444, r1
32 movb_reg_disp12
: # Test 8-bit gr -> @(disp12,gr)
41 assertreg _bdst-
444, r1
42 assertmem _bdst
, 0xa5000000
44 movw_disp12_reg
: # Test 16-bit @(disp12,gr) -> gr
53 assertreg _wsrc-
444, r1
56 movw_reg_disp12
: # Test 16-bit gr -> @(disp12,gr)
65 assertreg _wdst-
444, r1
66 assertmem _wdst
, 0xa5a50000
68 movl_disp12_reg
: # Test 32-bit @(disp12,gr) -> gr
77 assertreg _lsrc-
444, r1
78 assertreg
0x55555555, r2
80 movl_reg_disp12
: # Test 32-bit gr -> @(disp12,gr)
89 assertreg _ldst-
444, r1
90 assertmem _ldst
, 0xa5a5a5a5