Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: Nitish Kumar Mishra <mishra.nitish.88@gmail.com>
To: David Edelsohn <dje.gcc@gmail.com>
Cc: Pedro Alves <palves@redhat.com>,
	"gdb@sourceware.org" <gdb@sourceware.org>,
	Yao Qi <qiyaoltc@gmail.com>
Subject: Re: Issue with Latest GDB on AIX with GCC-6.12
Date: Thu, 09 Feb 2017 12:15:00 -0000	[thread overview]
Message-ID: <CACC+hkgC3thP2BdB-dBV5Zh_CLf2NSfeUiHSz1mHivFOXTpDUg@mail.gmail.com> (raw)
In-Reply-To: <CACC+hkgFOO6xRk38-jUhpyt+HGHiEeD60RDpi_5KX4XD+kA=1w@mail.gmail.com>

Hi all,
While sending the previous mail the statements got broken.
I am not sure if it is understandable. So, trying again :)

1. GDB with GCC-4.8.5, 32 bit mode, with or without static
    options : NOT WORKING.
2. GDB with GCC-4.8.5, 64 bit mode, with or without static
    options : WORKING FINE
3. GDB with GCC-6.1, 64 bit mode, with static options : NOT WORKING
4. GDB with GCC-6.1, 64 bit mode, without static options : COMPILATION ERROR.

P.S.: Static options means: -static-libstdc++ -static-libgcc
----------------

Thanks,
Nitish

On Thu, Feb 9, 2017 at 5:35 PM, Nitish Kumar Mishra
<mishra.nitish.88@gmail.com> wrote:
> Hi All !
> Here is my findings about GCC- 4.8.5 and 6.1:
>
>
> GCC-4.8.5 : 32 bit :::: (a) static linking to libstdc++
> -----------------> [process getting terminated (not working)]
>                                 (b) dynamic linking
> ------------------------------>  [process getting terminated (not
> working)]
>                   64 bit :::: (a) static linking to libstdc++
> -----------------> [working fine]
>                                 (b) dynamic linking
> -------------------------------> [working fine]
>
> GCC-6.1: 64 bit :::: (a) static linking to libstdc++
> ---------------------> [process getting terminated (not working)]
>                              (b) dynamic linking
> ----------------------------------> [Unable to compile (compilation
> error)]
>
>
> Above, static linking meant WITH option -static-libstdc++
> -static-libgcc and dynamic meant WITHOUT those options.
>
> --------------------------------------------
>
> Thanks,
> Nitish
>
>
> On Thu, Feb 9, 2017 at 10:21 AM, Nitish Kumar Mishra
> <mishra.nitish.88@gmail.com> wrote:
>> Hi David !
>>
>>>>GDB is linked with static libstdc++ and libgcc.
>>>>-static-libstdc++ -static-libgcc
>>>>Is your small test using those options?
>>
>> Yes, I used those static options. I am using readline library in my
>> test program and compiling it with gcc-6.1
>> like this:
>> g++ -g test.c -o test -static-libstdc++ -static-libgcc
>> -I/opt/freeware/include -lreadline
>> and the binary is working fine means I am able to catch the exceptions.
>>
>>>>Can you try linking GDB and testing GDB *without* those options?
>> ----Today I will be working on this---
>>
>> Thanks,
>> Nitish
>>
>>
>> On Wed, Feb 8, 2017 at 7:02 PM, David Edelsohn <dje.gcc@gmail.com> wrote:
>>> On Wed, Feb 8, 2017 at 7:06 AM, Pedro Alves <palves@redhat.com> wrote:
>>>> On 02/08/2017 06:16 AM, Nitish Kumar Mishra wrote:
>>>>
>>>>> I tried adding try/catch block earlier in throw_it and
>>>>> throw_exception_cxx functions
>>>>> but got no significant results.
>>>>> I had tried adding try catch block in these functions:
>>>>> kill_command
>>>>> command_handler
>>>>> command_line_handler
>>>>> execute_command
>>>>> throw_it
>>>>> throw_exception_cxx,
>>>>> but no progress. Output is exactly same as we got earlier (Other than
>>>>> extra frames for new
>>>>> try catch functions). None of the print statements in catch blocks for
>>>>> above functions worked.
>>>>
>>>> Eh, it sounds like _no_ exception catching works then?  I just
>>>> confirmed now that at least on GNU/Linux, GDB does not throw any
>>>> exception internally during startup.  This backtrace in question may
>>>> well not be special at all, and may be that _all_ exception catching
>>>> is broken.  I'd try experimenting with simple things like:
>>>>
>>>> try
>>>> {
>>>>   throw 1;
>>>> }
>>>> catch (...)
>>>> {
>>>>    printf (....);
>>>> }
>>>>
>>>> right at the start of gdb's main().  Not in a separately
>>>> compiled test program, but really inside gdb, to avoid
>>>> differences in how gdb vs the test program is built.
>>>>
>>>> It could also be that this is only triggered due to
>>>> GDB's binary size, hence not triggered in a small program -- I
>>>> recall that there was some trouble with the size of some sessions
>>>> and the linker in the AIX 7.1 box couldn't link gdb, or something
>>>> like that?  Maybe that's not fully/correctly sorted out.
>>>
>>> Nitish,
>>>
>>> GDB is linked with static libstdc++ and libgcc.
>>>
>>> -static-libstdc++ -static-libgcc
>>>
>>> Is your small test using those options?
>>>
>>> Can you try linking GDB and testing GDB *without* those options?
>>>
>>> Thanks, David


  reply	other threads:[~2017-02-09 12:15 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-28 23:56 David Edelsohn
2017-01-29  1:11 ` David Edelsohn
2017-01-31 13:09   ` Pedro Alves
2017-02-07  8:05     ` Nitish Kumar Mishra
2017-02-07 10:30       ` Pedro Alves
2017-02-07 13:44         ` David Edelsohn
2017-02-07 13:57           ` Pedro Alves
2017-02-07 14:16             ` David Edelsohn
2017-02-08  6:16               ` Nitish Kumar Mishra
2017-02-08  7:04                 ` Nitish Kumar Mishra
2017-02-08 12:06                 ` Pedro Alves
2017-02-08 13:32                   ` David Edelsohn
2017-02-09  4:51                     ` Nitish Kumar Mishra
2017-02-09 12:05                       ` Nitish Kumar Mishra
2017-02-09 12:15                         ` Nitish Kumar Mishra [this message]
2017-02-09 15:50                           ` David Edelsohn
2017-02-10  7:22                             ` Nitish Kumar Mishra
2017-02-10 15:52                               ` David Edelsohn
2017-02-12 21:05                                 ` David Edelsohn
2017-02-12 23:52                                   ` Pedro Alves
2017-02-13 15:02                                     ` David Edelsohn
2017-02-13 15:19                                       ` Eli Zaretskii
2017-02-13 15:38                                         ` Nitish Kumar Mishra
2017-02-20 11:22                                           ` Nitish Kumar Mishra
2017-02-20 11:25                                             ` Nitish Kumar Mishra
2017-02-20 11:37                                               ` Nitish Kumar Mishra
2017-02-21  8:01                                                 ` Nitish Kumar Mishra
2017-02-21 14:47                                                   ` David Edelsohn
  -- strict thread matches above, loose matches on Subject: below --
2017-01-25 10:54 Nitish Kumar Mishra
2017-01-25 11:12 ` Pedro Alves
2017-01-25 13:52   ` Pedro Alves
2017-01-25 14:01     ` Pedro Alves
2017-01-25 14:38     ` Yao Qi
2017-01-25 14:44       ` Pedro Alves

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=CACC+hkgC3thP2BdB-dBV5Zh_CLf2NSfeUiHSz1mHivFOXTpDUg@mail.gmail.com \
    --to=mishra.nitish.88@gmail.com \
    --cc=dje.gcc@gmail.com \
    --cc=gdb@sourceware.org \
    --cc=palves@redhat.com \
    --cc=qiyaoltc@gmail.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