binutils-gdb/ld/testsuite/ld-avr/lds-mega.s
Denis Chertykov 1857fe72af Print symbol names in comments for LDS/STS disassembly.
This patch adds default data address space origin (0x800000) to the symbol addresses.
when disassemble lds/sts instructions. So that symbol names shall be printed in comments
for lds/sts instructions disassemble.

ld/
	* testsuite/ld-avr/lds-mega.d: New test.
	* testsuite/ld-avr/lds-mega.s: New test source.
	* testsuite/ld-avr/lds-tiny.d: New test.
	* testsuite/ld-avr/lds-tiny.s: New test source.

opcodes/
	* avr-dis.c (avr_operand): Add default data address space origin (0x800000) to the
	address and set as symbol address for LDS/ STS immediate operands.
2016-06-09 19:00:57 +03:00

21 lines
278 B
ArmAsm

.file "lds-mega.s"
__tmp_reg__ = 0
.text
.global main
.type main, @function
main:
.L__stack_usage = 0
lds r24,256
mov __tmp_reg__,r24
lsl r0
sbc r25,r25
sts myvar2+1,r25
sts myvar2,r24
ldi r24,0
ldi r25,0
ret
.size main, .-main
.comm myvar2,2,1
.comm myvar1,2,1