From 1d3787499d6edd07b30f3fc7b26962a1c695b8a4 Mon Sep 17 00:00:00 2001 From: Nick Clifton Date: Wed, 9 Oct 2019 13:48:06 +0100 Subject: Fix the disassembly of the LDS and STS instructions of the AVR architecture. PR 25041 opcodes * avr-dis.c (avr_operand): Fix construction of address for lds/sts instructions. gas * testsuite/gas/avr/pr25041.s: New test. * testsuite/gas/avr/pr25041.d: New test driver. --- gas/testsuite/gas/avr/pr25041.d | 9 +++++++++ gas/testsuite/gas/avr/pr25041.s | 4 ++++ 2 files changed, 13 insertions(+) create mode 100644 gas/testsuite/gas/avr/pr25041.d create mode 100644 gas/testsuite/gas/avr/pr25041.s (limited to 'gas/testsuite') diff --git a/gas/testsuite/gas/avr/pr25041.d b/gas/testsuite/gas/avr/pr25041.d new file mode 100644 index 0000000..086fe0a --- /dev/null +++ b/gas/testsuite/gas/avr/pr25041.d @@ -0,0 +1,9 @@ +#name: PR 25041 (correct generation of lds/sts addresses) +#as: -m "attiny10" +#target: avr-*-* +#objdump: -Dm"avr:100" + +#... +00000000 <_start>: + 0: 00 a0 lds r16, 0x80 ; 0x800080 <_start\+0x800080> + 2: 00 a8 sts 0x80, r16 ; 0x800080 <_start\+0x800080> diff --git a/gas/testsuite/gas/avr/pr25041.s b/gas/testsuite/gas/avr/pr25041.s new file mode 100644 index 0000000..b5745b4 --- /dev/null +++ b/gas/testsuite/gas/avr/pr25041.s @@ -0,0 +1,4 @@ + +_start: + lds r16, 0x80 + sts 0x80, r16 -- cgit v1.1