From: Pedro Alves <palves@redhat.com>
To: Omair Javaid <omair.javaid@linaro.org>
Cc: Yao Qi <yao@codesourcery.com>, gdb-patches@sourceware.org
Subject: Re: [PATCH] testsuite/gdb.dwarf2: Fix for dw2-ifort-parameter failure on ARM
Date: Thu, 16 Jan 2014 16:24:00 -0000 [thread overview]
Message-ID: <52D80798.2050304@redhat.com> (raw)
In-Reply-To: <52D7E9D7.80309@linaro.org>
On 01/16/2014 02:16 PM, Omair Javaid wrote:
> On Thu 16 Jan 2014 07:00:37 PM PKT, Pedro Alves wrote:
>> On 01/16/2014 01:55 PM, Omair Javaid wrote:
>>>>> diff --git a/gdb/testsuite/gdb.dwarf2/dw2-ifort-parameter.c b/gdb/testsuite/gdb.dwarf2/dw2-ifort-parameter.c
>>>>> index 361c44d..c866b0f 100644
>>>>> --- a/gdb/testsuite/gdb.dwarf2/dw2-ifort-parameter.c
>>>>> +++ b/gdb/testsuite/gdb.dwarf2/dw2-ifort-parameter.c
>>>>> @@ -29,3 +29,9 @@ main (void)
>>>>> func ();
>>>>> return 0;
>>>>> }
>>>>> +
>>>>> +/* Addresses represented as data symbols, thus without Thumb (etc.)
>>>>> + mode bits. The dw2-ifort-parameter-debug.S file uses this as
>>>>> + func's low_pc/high_pc. */
>>>>> +extern void *func_addr __attribute__ ((alias ("func")));
>>>>> +extern void *main_addr __attribute__ ((alias ("main")));
>>> Patch doesnt fix the issue and builds after making changes to alias definition like:
>>
>> Odd. Are you saying the patch didn't build for you? It did for
>> me, in Thumb mode, and the debug info I saw looked right (no
>> thumb bit).
>>
>>> extern void func_addr() __attribute__ ((alias ("func")));
>>> extern void main_addr() __attribute__ ((alias ("main")));
>>
>> ...
>>> but issues remains the same.
>>
>> That's expected, as the whole point was making a data symbol
>> (void *), but that change makes it a function again (thus
>> ends up with the thumb bit set again).
>>
>
> I am using gcc version 4.8.1 (Ubuntu/Linaro 4.8.1-10ubuntu9)
> Patch fails to build with following error:
>
> gdb compile failed, ./gdb.dwarf2/dw2-ifort-parameter.c:37:15: error:
> 'func_addr' alias in between function and variable is not supported
> extern void * func_addr __attribute__ ((alias ("func")));
> ^
> ./gdb.dwarf2/dw2-ifort-parameter.c:23:1: warning: 'func' aliased
> declaration [enabled by default]
> func (void)
> ^
> ./gdb.dwarf2/dw2-ifort-parameter.c:38:15: error: 'main_addr' alias in
> between function and variable is not supported
> extern void * main_addr __attribute__ ((alias ("main")));
> ^
> ./gdb.dwarf2/dw2-ifort-parameter.c:28:1: warning: 'main' aliased
> declaration [enabled by default]
> main (void)
> ^
OK. Well, it seems to me that the root of this whole test's problem
is the exact same as the one being discussed in the
"Fix possible alignment issue with dw2-dir-file-name test case"
thread, for ppc64. That is, using a function symbol for
the function's low_pc/high_pc range is not OK. The way we fix
one should fix the other too.
--
Pedro Alves
prev parent reply other threads:[~2014-01-16 16:24 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <CANW4E-2bQYjx6YdR3qGyKUsQa_KOrtmkWsZYqKzcuQBF==RPpw@mail.gmail.com>
2013-07-15 10:25 ` Omair Javaid
2013-07-16 2:53 ` Yao Qi
2013-09-19 15:31 ` Omair Javaid
2013-10-01 9:53 ` Omair Javaid
2013-11-11 9:53 ` Yao Qi
2014-01-16 9:09 ` Omair Javaid
2014-01-16 9:17 ` Will Newton
2014-01-16 9:48 ` Pedro Alves
2014-01-16 9:51 ` Pedro Alves
2014-01-16 10:26 ` Omair Javaid
2014-01-16 12:35 ` Pedro Alves
2014-01-16 13:55 ` Omair Javaid
2014-01-16 14:00 ` Pedro Alves
2014-01-16 14:17 ` Omair Javaid
2014-01-16 16:24 ` Pedro Alves [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=52D80798.2050304@redhat.com \
--to=palves@redhat.com \
--cc=gdb-patches@sourceware.org \
--cc=omair.javaid@linaro.org \
--cc=yao@codesourcery.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox