This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [patch] Enable dwarf unwind for AVR target
- From: Pedro Alves <palves at redhat dot com>
- To: "Sivanupandi, Pitchumani" <Pitchumani dot Sivanupandi at atmel dot com>, "troth at openavr dot org" <troth at openavr dot org>, "brobecker at adacore dot com" <brobecker at adacore dot com>, "gdb-patches at sourceware dot org" <gdb-patches at sourceware dot org>
- Date: Mon, 04 Jan 2016 13:57:35 +0000
- Subject: Re: [patch] Enable dwarf unwind for AVR target
- Authentication-results: sourceware.org; auth=none
- References: <CAC140656783604CABA6AE60C2A6D5A4CA3B38C1 at penmbx02 dot corp dot atmel dot com>
On 01/04/2016 08:01 AM, Sivanupandi, Pitchumani wrote:
> - AVR_NUM_PSEUDO_REGS = 1,
> + AVR_DWARF2_PC_REGNUM = 36 /*LR*/,
It's hard to comment without some explanation for the design choices
in the patch, and/or some understanding of what this register is.
Seems odd that you create the register and then avr_pseudo_register_read
already returns <unavailable>? Why did you need to add it? Is this a
real machine register? What's LR?
> + AVR_NUM_PSEUDO_REGS = 2,
>
> AVR_PC_REG_INDEX = 35, /* index into array of registers */
>
> @@ -211,7 +213,7 @@ avr_register_name (struct gdbarch *gdbarch, int regnum)
> "r16", "r17", "r18", "r19", "r20", "r21", "r22", "r23",
> "r24", "r25", "r26", "r27", "r28", "r29", "r30", "r31",
> "SREG", "SP", "PC2",
> - "pc"
> + "pc", "LR"
> };
Thanks,
Pedro Alves