This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: setting a breakpoint on a break statement
- From: Ian Lance Taylor <iant at google dot com>
- To: Tristan Gingold <gingold at adacore dot com>
- Cc: gcc at gcc dot gnu dot org
- Date: 14 Mar 2007 07:16:43 -0700
- Subject: Re: setting a breakpoint on a break statement
- References: <7569E02B-3F10-4961-AE6F-BF56D88138F5@adacore.com>
Tristan Gingold <gingold@adacore.com> writes:
> in some cases, a breakpoint can't be set on a continue or break
> statement. Here is a simple example:
> The reason is quiet simple: even at -O0 -g, there is no insn (and no
> BB) corresponding to the break/continue statement.
> Here is a small patch which fixes the issue.
> I wonder if this is the right approach. This patch makes the code
> generated at -O0 uglier...
Thanks for sending the patch. Procedural note: patches should be sent
to gcc-patches@gcc.gnu.org, and should have a ChangeLog entry.
I don't think it is appropriate to change the meaning of
forwarder_block_p. And I'm not sure why you need that patch anyhow,
considering the existing code in cleanup_tree_cfg_1.
Also you should ideally add a test case.
Thanks.
Ian