public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug debug/78685] -Og generates too many "<optimized out>"s
       [not found] <bug-78685-4@http.gcc.gnu.org/bugzilla/>
@ 2021-05-18 13:36 ` egallager at gcc dot gnu.org
  2021-05-18 15:35 ` rsandifo at gcc dot gnu.org
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 5+ messages in thread
From: egallager at gcc dot gnu.org @ 2021-05-18 13:36 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78685

Eric Gallager <egallager at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |egallager at gcc dot gnu.org,
                   |                            |fredrik at dolda2000 dot com,
                   |                            |john.carter at taitradio dot com,
                   |                            |marxin at gcc dot gnu.org,
                   |                            |philipp.lucas at siemens dot com,
                   |                            |yuxian.chen at intel dot com

--- Comment #19 from Eric Gallager <egallager at gcc dot gnu.org> ---
This bug came up on the gcc-help mailing list here:
https://gcc.gnu.org/pipermail/gcc-help/2021-May/140304.html

...and, while I'm here, let me update a few things...

(In reply to rsandifo@gcc.gnu.org from comment #18)
> (In reply to Eric Gallager from comment #17)
> > Richard Sandiford had a series of patches radically overhauling how -Og
> > works in general that might affect this bug:
> > https://gcc.gnu.org/ml/gcc-patches/2019-06/msg01392.html
> > cc-ing him so he can comment on if it does in fact affect this bug.
> 
> Yeah, part 2 of the series fixes this PR:
> https://gcc.gnu.org/ml/gcc-patches/2019-06/msg01394.html

Has this series been merged yet? Or at least pinged recently?

(also, I'm redoing some CCs that seem to have been accidentally removed from
the CC list without showing up in the bug history as having been removed;
presumably this was from the server migration...)

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug debug/78685] -Og generates too many "<optimized out>"s
       [not found] <bug-78685-4@http.gcc.gnu.org/bugzilla/>
  2021-05-18 13:36 ` [Bug debug/78685] -Og generates too many "<optimized out>"s egallager at gcc dot gnu.org
@ 2021-05-18 15:35 ` rsandifo at gcc dot gnu.org
  2021-12-13 13:38 ` mark at hotpy dot org
                   ` (2 subsequent siblings)
  4 siblings, 0 replies; 5+ messages in thread
From: rsandifo at gcc dot gnu.org @ 2021-05-18 15:35 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78685

--- Comment #20 from rsandifo at gcc dot gnu.org <rsandifo at gcc dot gnu.org> ---
(In reply to Eric Gallager from comment #19)
> (In reply to rsandifo@gcc.gnu.org from comment #18)
> > (In reply to Eric Gallager from comment #17)
> > > Richard Sandiford had a series of patches radically overhauling how -Og
> > > works in general that might affect this bug:
> > > https://gcc.gnu.org/ml/gcc-patches/2019-06/msg01392.html
> > > cc-ing him so he can comment on if it does in fact affect this bug.
> > 
> > Yeah, part 2 of the series fixes this PR:
> > https://gcc.gnu.org/ml/gcc-patches/2019-06/msg01394.html
> 
> Has this series been merged yet? Or at least pinged recently?
It was only an RFC and wasn't ready for inclusion.  There didn't
seem to be much support for the idea so TBH I've mostly dropped it.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug debug/78685] -Og generates too many "<optimized out>"s
       [not found] <bug-78685-4@http.gcc.gnu.org/bugzilla/>
  2021-05-18 13:36 ` [Bug debug/78685] -Og generates too many "<optimized out>"s egallager at gcc dot gnu.org
  2021-05-18 15:35 ` rsandifo at gcc dot gnu.org
@ 2021-12-13 13:38 ` mark at hotpy dot org
  2023-10-09  9:17 ` rguenth at gcc dot gnu.org
  2024-02-28  7:47 ` pinskia at gcc dot gnu.org
  4 siblings, 0 replies; 5+ messages in thread
From: mark at hotpy dot org @ 2021-12-13 13:38 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78685

mark at hotpy dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |mark at hotpy dot org

--- Comment #21 from mark at hotpy dot org ---
Debugging CPython is a real pain with GCC.

(gdb) p almost-any-useful-value
value has been optimised out

Isn't the point of -Og that values should be visible to the debugger?

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug debug/78685] -Og generates too many "<optimized out>"s
       [not found] <bug-78685-4@http.gcc.gnu.org/bugzilla/>
                   ` (2 preceding siblings ...)
  2021-12-13 13:38 ` mark at hotpy dot org
@ 2023-10-09  9:17 ` rguenth at gcc dot gnu.org
  2024-02-28  7:47 ` pinskia at gcc dot gnu.org
  4 siblings, 0 replies; 5+ messages in thread
From: rguenth at gcc dot gnu.org @ 2023-10-09  9:17 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78685

--- Comment #22 from Richard Biener <rguenth at gcc dot gnu.org> ---
extern void abort (void);
int __attribute__((noipa)) foo ()
{
  return 1;
} 

int main()
{
  int res = foo ();
  if (res != 0)
    abort ();
}

Asks for call clobbered registers associated with user variables to be
preserved around calls.  In this case the value of 'res' ($eax on x86)
is no longer available when receiving SIGABRT, instead it's quickly
clobbered.

The more aggressive variant would be to force all user variables to the
stack (but then we still have to put saves around calls, in this case
it's similar to what Jakub says with uses after the call).

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug debug/78685] -Og generates too many "<optimized out>"s
       [not found] <bug-78685-4@http.gcc.gnu.org/bugzilla/>
                   ` (3 preceding siblings ...)
  2023-10-09  9:17 ` rguenth at gcc dot gnu.org
@ 2024-02-28  7:47 ` pinskia at gcc dot gnu.org
  4 siblings, 0 replies; 5+ messages in thread
From: pinskia at gcc dot gnu.org @ 2024-02-28  7:47 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78685

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |lukas.graetz@tu-darmstadt.d
                   |                            |e

--- Comment #23 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
*** Bug 114144 has been marked as a duplicate of this bug. ***

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2024-02-28  7:47 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <bug-78685-4@http.gcc.gnu.org/bugzilla/>
2021-05-18 13:36 ` [Bug debug/78685] -Og generates too many "<optimized out>"s egallager at gcc dot gnu.org
2021-05-18 15:35 ` rsandifo at gcc dot gnu.org
2021-12-13 13:38 ` mark at hotpy dot org
2023-10-09  9:17 ` rguenth at gcc dot gnu.org
2024-02-28  7:47 ` pinskia at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).