This is the mail archive of the
mailing list for the GCC project.
Re: Modify gcc for use with gdb (issue5132047)
- From: Richard Guenther <richard dot guenther at gmail dot com>
- To: Diego Novillo <dnovillo at google dot com>
- Cc: Mike Stump <mikestump at comcast dot net>, Jakub Jelinek <jakub at redhat dot com>, Lawrence Crowl <crowl at google dot com>, reply at codereview dot appspotmail dot com, gcc-patches at gcc dot gnu dot org
- Date: Thu, 6 Oct 2011 10:58:34 +0200
- Subject: Re: Modify gcc for use with gdb (issue5132047)
- References: <20110926220500.9254022266A@jade.mtv.corp.google.com> <20110927071447.GJ2687@tyan-ft48-01.lab.bos.redhat.com> <CAFiYyc1F+qt8c4XTBn=Jp2WCdOLppkWaPahnmxUfd97K43v7UA@mail.gmail.com> <CAFiYyc14=_KNGBqm9-6C3ZMCLjPmP1UDzbmZOsPLFpi20=UEpA@mail.gmail.com> <4E8C5910.firstname.lastname@example.org> <DBDF1E7C-CF28-4ED6-9C12-D024787F48D5@comcast.net> <CAD_=9DQR0BeTRpmVLrgZLeCV6hRLEDGZJQ7M8OR0wP0Uyct55w@mail.gmail.com>
On Wed, Oct 5, 2011 at 8:51 PM, Diego Novillo <email@example.com> wrote:
> On Wed, Oct 5, 2011 at 14:20, Mike Stump <firstname.lastname@example.org> wrote:
>> On Oct 5, 2011, at 6:18 AM, Diego Novillo wrote:
>>> I think we need to find a solution for this situation.
>> The solution Apple found and implemented is a __nodebug__ attribute, as can be seen in Apple's gcc.
>> We use it like so:
>> #define __always_inline__ __always_inline__, __nodebug__
>> #undef __always_inline__
>> in headers like mmintrn.h:
>> __STATIC_INLINE void __attribute__((__always_inline__))
>> /* APPLE LOCAL end radar 5618945 */
>> _mm_empty (void)
>> ?__builtin_ia32_emms ();
> Ah, nice. ?Though, one of the things I am liking more and more about
> the blacklist solution is that it (a) does not need any modifications
> to the source code, and (b) it works with no-inline functions as well.
> This gives total control to the developer. ?I would blacklist a bunch
> of functions I never care to go into, for instance. ?Others may choose
> to blacklist a different set. ?And you can change that from debug
> session to the next.
> I agree with Jakub that artificial functions should be blacklisted
> automatically, however.
> Richi, Jakub, if the blacklist solution was implemented in GCC would
> you agree with promoting these macros into inline functions? ?This is
> orthogonal to http://sourceware.org/bugzilla/show_bug.cgi?id=13263, of
I know you are on to that C++ thing and ending up returning a reference
to make it an lvalue. Which I very much don't like (please, if you go
that route add _set functions and lower the case of the macros).
What's the other advantage of using inline functions? The gdb
annoyance with the macros can be solved with the .gdbinit macro
defines (which might be nice to commit to SVN btw).
> Thanks. ?Diego.