Skip to content
  • Øyvind Harboe's avatar
    target: mdX/mwX on target were badly broken · 099ffc75
    Øyvind Harboe authored
    
    
    - incorrect parsing of arguments
    - mdX didn't display arguments correctly
    
    I don't think anyone ever used that code path :-)
    
    Did you know that "target mdw" and mdw are very different?
    
    for {set i 0} {$i < 256} {set i [expr $i+1]} {mwb [expr 0x2000000+$i] $i}
    
     mdw 0x2000000 0x10
    0x02000000: 03020100 07060504 0b0a0908 0f0e0d0c 13121110 17161514 1b1a1918 1f1e1d1c
    0x02000020: 23222120 27262524 2b2a2928 2f2e2d2c 33323130 37363534 3b3a3938 3f3e3d3c
    
    > zy1000.cpu mdb 0x2000000 0x20
    0x02000000 00 01 02 03 04 05 06 07 08 09 0a 0b 0c 0d 0e 0f ................
    0x02000010 10 11 12 13 14 15 16 17 18 19 1a 1b 1c 1d 1e 1f ................
    > zy1000.cpu mdh 0x2000000 0x20
    0x02000000 0100 0302 0504 0706 0908 0b0a 0d0c 0f0e ................
    0x02000010 1110 1312 1514 1716 1918 1b1a 1d1c 1f1e ................
    0x02000020 2120 2322 2524 2726 2928 2b2a 2d2c 2f2e  !"#$%&'()*+,-./
    0x02000030 3130 3332 3534 3736 3938 3b3a 3d3c 3f3e 0123456789:;<=>?
    > zy1000.cpu mdw 0x2000000 0x20
    0x02000000 03020100 07060504 0b0a0908 0f0e0d0c ................
    0x02000010 13121110 17161514 1b1a1918 1f1e1d1c ................
    0x02000020 23222120 27262524 2b2a2928 2f2e2d2c  !"#$%&'()*+,-./
    0x02000030 33323130 37363534 3b3a3938 3f3e3d3c 0123456789:;<=>?
    0x02000040 43424140 47464544 4b4a4948 4f4e4d4c @ABCDEFGHIJKLMNO
    0x02000050 53525150 57565554 5b5a5958 5f5e5d5c PQRSTUVWXYZ[\]^_
    0x02000060 63626160 67666564 6b6a6968 6f6e6d6c `abcdefghijklmno
    0x02000070 73727170 77767574 7b7a7978 7f7e7d7c pqrstuvwxyz{|}~.
    
    Signed-off-by: default avatarØyvind Harboe <oyvind.harboe@zylin.com>
    099ffc75