qemu/tests/tcg/lm32/test_lbu.S
<<
>>
Prefs
   1.include "macros.inc"
   2
   3start
   4
   5test_name LBU_1
   6load r1 data
   7lbu r3, (r1+0)
   8check_r3 0x7e
   9
  10test_name LBU_2
  11load r1 data
  12lbu r3, (r1+1)
  13check_r3 0x7f
  14
  15test_name LBU_3
  16load r1 data
  17lbu r3, (r1+-1)
  18check_r3 0x7d
  19
  20test_name LBU_4
  21load r1 data_msb
  22lbu r3, (r1+0)
  23check_r3 0xfe
  24
  25test_name LBU_5
  26load r1 data_msb
  27lbu r3, (r1+1)
  28check_r3 0xff
  29
  30test_name LBU_6
  31load r1 data_msb
  32lbu r3, (r1+-1)
  33check_r3 0xfd
  34
  35test_name LBU_7
  36load r3 data
  37lbu r3, (r3+0)
  38check_r3 0x7e
  39
  40end
  41
  42.data
  43        .align 4
  44        .byte 0x7a, 0x7b, 0x7c, 0x7d
  45data:
  46        .byte 0x7e, 0x7f, 0x70, 0x71
  47        .byte 0xfa, 0xfb, 0xfc, 0xfd
  48data_msb:
  49        .byte 0xfe, 0xff, 0xf0, 0xf1
  50