From: Christophe Lyon <christophe.lyon@linaro.org>
To: Alexandre Oliva <aoliva@redhat.com>
Cc: Jeff Law <law@redhat.com>,
Richard Biener <richard.guenther@gmail.com>,
Jason Merrill <jason@redhat.com>,
GCC Patches <gcc-patches@gcc.gnu.org>
Subject: Re: [SFN+LVU+IEPM v4 6/9] [SFN] Introduce -gstatement-frontiers option, enable debug markers
Date: Tue, 12 Dec 2017 09:16:00 -0000 [thread overview]
Message-ID: <CAKdteOYKnQc7cffdLYOzFyyXFccbhAU=nsnPWgHjuy1DmT1s_Q@mail.gmail.com> (raw)
In-Reply-To: <ork1xsvf8p.fsf@lxoliva.fsfla.org>
Hi,
On 12 December 2017 at 03:42, Alexandre Oliva <aoliva@redhat.com> wrote:
> On Dec 7, 2017, Jeff Law <law@redhat.com> wrote:
>
>> On 11/09/2017 07:34 PM, Alexandre Oliva wrote:
>>> Introduce a command line option to enable statement frontiers, enabled
>>> by default in optimized builds with DWARF2+ debug information.
>> OK once all prereqs are ack'd.
>
> Thanks, here's what's installed, FTR:
>
> From aa2fd8850c18861c8e3811b9174b0b1667111783 Mon Sep 17 00:00:00 2001
> From: aoliva <aoliva@138bc75d-0d04-0410-961f-82ee72b054a4>
> Date: Tue, 12 Dec 2017 02:16:31 +0000
> Subject: [PATCH 6/7] [SFN] Introduce -gstatement-frontiers option, enable
> debug markers
>
> Introduce a command line option to enable statement frontiers, enabled
> by default in optimized builds with DWARF2+ debug information.
>
> This patch depends on an earlier patch that completed the
> infrastructure for debug markers, and on another patch that turns -g
> into a negatable option prefix.
>
> for gcc/ChangeLog
>
> * common.opt (gstatement-frontiers): New, setting
> debug_nonbind_markers_p.
> * rtl.h (MAY_HAVE_DEBUG_MARKER_INSNS): Activate.
> * toplev.c (process_options): Autodetect value for debug statement
> frontiers option.
> * tree.h (MAY_HAVE_DEBUG_MARKER_STMTS): Activate.
> * doc/invoke.texi (gstatement-frontiers, gno-statement-frontiers): New.
>
> git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@255569 138bc75d-0d04-0410-961f-82ee72b054a4
Since this was checked in, I've noticed GCC/libatomic build failures
on ARM targets when configuring
--with-mode thumb (--with-mode arm is OK).
I'm seeing this:
/tmp/923972_2.tmpdir/aci-gcc-fsf/builds/gcc-fsf-gccsrc-thumb/obj-arm-none-linux-gnueabi/gcc3/./gcc/xgcc
-B/tmp/923972_2.tmpdir/aci-gcc-fsf/builds/gcc-fsf-gccsrc-thumb/obj-arm-none-
linux-gnueabi/gcc3/./gcc/
-B/tmp/923972_2.tmpdir/aci-gcc-fsf/builds/gcc-fsf-gccsrc-thumb/tools/arm-none-linux-gnueabi/bin/
-B/tmp/923972_2.tmpdir/aci-gcc-fsf/builds/gcc-fsf-gccsrc-thumb/tools/arm-non
e-linux-gnueabi/lib/ -isystem
/tmp/923972_2.tmpdir/aci-gcc-fsf/builds/gcc-fsf-gccsrc-thumb/tools/arm-none-linux-gnueabi/include
-isystem /tmp/923972_2.tmpdir/aci-gcc-fsf/builds/gcc-fsf-gccsrc-thumb/t
ools/arm-none-linux-gnueabi/sys-include -DHAVE_CONFIG_H
-I/tmp/923972_2.tmpdir/aci-gcc-fsf/sources/gcc-fsf/gccsrc/libatomic/config/arm
-I/tmp/923972_2.tmpdir/aci-gcc-fsf/sources/gcc-fsf/gccsrc/libato
mic/config/linux/arm
-I/tmp/923972_2.tmpdir/aci-gcc-fsf/sources/gcc-fsf/gccsrc/libatomic/config/posix
-I/tmp/923972_2.tmpdir/aci-gcc-fsf/sources/gcc-fsf/gccsrc/libatomic
-I. -Wall -Werror -pthread -g
-O2 -MT gload.lo -MD -MP -MF .deps/gload.Tpo -c
/tmp/923972_2.tmpdir/aci-gcc-fsf/sources/gcc-fsf/gccsrc/libatomic/gload.c
-fPIC -DPIC -o .libs/gload.o
/tmp/923972_2.tmpdir/ccxBYdCX.s: Assembler messages:
/tmp/923972_2.tmpdir/ccxBYdCX.s: Error: unaligned opcodes detected in
executable segment
make[4]: *** [gload.lo] Error 1
make[4]: Leaving directory
`/tmp/923972_2.tmpdir/aci-gcc-fsf/builds/gcc-fsf-gccsrc-thumb/obj-arm-none-linux-gnueabi/gcc3/arm-none-linux-gnueabi/libatomic'
Christophe
> ---
> gcc/ChangeLog | 8 ++++++++
> gcc/common.opt | 4 ++++
> gcc/doc/invoke.texi | 12 ++++++++++++
> gcc/rtl.h | 2 +-
> gcc/toplev.c | 4 ++++
> gcc/tree.h | 2 +-
> 6 files changed, 30 insertions(+), 2 deletions(-)
>
> diff --git a/gcc/ChangeLog b/gcc/ChangeLog
> index 01bd2b9f49ad..a53e7b8173f5 100644
> --- a/gcc/ChangeLog
> +++ b/gcc/ChangeLog
> @@ -1,5 +1,13 @@
> 2017-12-12 Alexandre Oliva <aoliva@redhat.com>
>
> + * common.opt (gstatement-frontiers): New, setting
> + debug_nonbind_markers_p.
> + * rtl.h (MAY_HAVE_DEBUG_MARKER_INSNS): Activate.
> + * toplev.c (process_options): Autodetect value for debug statement
> + frontiers option.
> + * tree.h (MAY_HAVE_DEBUG_MARKER_STMTS): Activate.
> + * doc/invoke.texi (gstatement-frontiers, gno-statement-frontiers): New.
> +
> * cfgexpand.c (expand_gimple_basic_block): Handle begin stmt
> markers. Integrate source bind into debug stmt expand loop.
> (pass_expand::execute): Check debug marker limit. Avoid deep
> diff --git a/gcc/common.opt b/gcc/common.opt
> index 57b3cd7304ab..d80ae5b7f39b 100644
> --- a/gcc/common.opt
> +++ b/gcc/common.opt
> @@ -2936,6 +2936,10 @@ gstabs+
> Common Driver JoinedOrMissing Negative(gvms)
> Generate debug information in extended STABS format.
>
> +gstatement-frontiers
> +Common Driver Var(debug_nonbind_markers_p) Init(2)
> +Emit progressive recommended breakpoint locations.
> +
> gstrict-dwarf
> Common Driver Report Var(dwarf_strict) Init(0)
> Don't emit DWARF additions beyond selected version.
> diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi
> index 189b3e438fff..6402a5ae1734 100644
> --- a/gcc/doc/invoke.texi
> +++ b/gcc/doc/invoke.texi
> @@ -346,6 +346,7 @@ Objective-C and Objective-C++ Dialects}.
> -ggdb -grecord-gcc-switches -gno-record-gcc-switches @gol
> -gstabs -gstabs+ -gstrict-dwarf -gno-strict-dwarf @gol
> -gcolumn-info -gno-column-info @gol
> +-gstatement-frontiers -gno-statement-frontiers @gol
> -gvms -gxcoff -gxcoff+ -gz@r{[}=@var{type}@r{]} @gol
> -fdebug-prefix-map=@var{old}=@var{new} -fdebug-types-section @gol
> -fno-eliminate-unused-debug-types @gol
> @@ -7146,6 +7147,17 @@ Emit location column information into DWARF debugging information, rather
> than just file and line.
> This option is enabled by default.
>
> +@item -gstatement-frontiers
> +@item -gno-statement-frontiers
> +@opindex gstatement-frontiers
> +@opindex gno-statement-frontiers
> +This option causes GCC to create markers in the internal representation
> +at the beginning of statements, and to keep them roughly in place
> +throughout compilation, using them to guide the output of @code{is_stmt}
> +markers in the line number table. This is enabled by default when
> +compiling with optimization (@option{-Os}, @option{-O}, @option{-O2},
> +@dots{}), and outputting DWARF 2 debug information at the normal level.
> +
> @item -gz@r{[}=@var{type}@r{]}
> @opindex gz
> Produce compressed debug sections in DWARF format, if that is supported.
> diff --git a/gcc/rtl.h b/gcc/rtl.h
> index 4de167d982cf..3ef687e5a371 100644
> --- a/gcc/rtl.h
> +++ b/gcc/rtl.h
> @@ -816,7 +816,7 @@ struct GTY(()) rtvec_def {
> #define NONDEBUG_INSN_P(X) (INSN_P (X) && !DEBUG_INSN_P (X))
>
> /* Nonzero if DEBUG_MARKER_INSN_P may possibly hold. */
> -#define MAY_HAVE_DEBUG_MARKER_INSNS 0 /* debug_nonbind_markers_p */
> +#define MAY_HAVE_DEBUG_MARKER_INSNS debug_nonbind_markers_p
> /* Nonzero if DEBUG_BIND_INSN_P may possibly hold. */
> #define MAY_HAVE_DEBUG_BIND_INSNS flag_var_tracking_assignments
> /* Nonzero if DEBUG_INSN_P may possibly hold. */
> diff --git a/gcc/toplev.c b/gcc/toplev.c
> index 2f154960a170..b6e038d2f89d 100644
> --- a/gcc/toplev.c
> +++ b/gcc/toplev.c
> @@ -1536,6 +1536,10 @@ process_options (void)
> warning_at (UNKNOWN_LOCATION, 0,
> "var-tracking-assignments changes selective scheduling");
>
> + if (debug_nonbind_markers_p == AUTODETECT_VALUE)
> + debug_nonbind_markers_p = optimize && debug_info_level >= DINFO_LEVEL_NORMAL
> + && (write_symbols == DWARF2_DEBUG || write_symbols == VMS_AND_DWARF2_DEBUG);
> +
> if (flag_tree_cselim == AUTODETECT_VALUE)
> {
> if (HAVE_conditional_move)
> diff --git a/gcc/tree.h b/gcc/tree.h
> index 892a8ba7f707..83af3bcaf55f 100644
> --- a/gcc/tree.h
> +++ b/gcc/tree.h
> @@ -1124,7 +1124,7 @@ extern void omp_clause_range_check_failed (const_tree, const char *, int,
> ((int)TREE_INT_CST_LOW (VL_EXP_CHECK (NODE)->exp.operands[0]))
>
> /* Nonzero if gimple_debug_nonbind_marker_p() may possibly hold. */
> -#define MAY_HAVE_DEBUG_MARKER_STMTS 0 /* debug_nonbind_markers_p */
> +#define MAY_HAVE_DEBUG_MARKER_STMTS debug_nonbind_markers_p
> /* Nonzero if gimple_debug_bind_p() (and thus
> gimple_debug_source_bind_p()) may possibly hold. */
> #define MAY_HAVE_DEBUG_BIND_STMTS flag_var_tracking_assignments
> --
> 2.13.6
>
>
>
> --
> Alexandre Oliva, freedom fighter http://FSFLA.org/~lxoliva/
> You must be the change you wish to see in the world. -- Gandhi
> Be Free! -- http://FSFLA.org/ FSF Latin America board member
> Free Software Evangelist|Red Hat Brasil GNU Toolchain Engineer
next prev parent reply other threads:[~2017-12-12 9:16 UTC|newest]
Thread overview: 156+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-07-05 23:21 Introduce Statement Frontier Notes and Location Views Alexandre Oliva
2017-07-13 13:17 ` Alexandre Oliva
2017-08-18 22:49 ` Statement Frontier Notes, Location Views, and Inlined Entry Point Markers (was: Re: Introduce Statement Frontier Notes and Location Views) Alexandre Oliva
2017-08-21 12:35 ` Richard Biener
2017-08-22 22:44 ` Statement Frontier Notes, Location Views, and Inlined Entry Point Markers Alexandre Oliva
2017-08-23 12:33 ` Richard Biener
2017-08-25 16:41 ` Alexandre Oliva
2017-09-07 21:44 ` Joseph Myers
2017-09-21 2:24 ` Alexandre Oliva
2017-08-22 22:44 ` Alexandre Oliva
2017-08-23 12:12 ` Richard Biener
2017-08-25 15:26 ` Alexandre Oliva
2017-08-28 12:41 ` Richard Biener
2017-08-25 19:22 ` Alexandre Oliva
2017-09-01 1:07 ` Alexandre Oliva
2017-09-01 1:15 ` [PATCH 5/9] [SFN] Introduce -gstatement-frontiers option, enable debug markers Alexandre Oliva
2017-09-01 1:15 ` [PATCH 1/9] [SFN] adjust RTL insn-walking API Alexandre Oliva
2017-09-01 1:15 ` [PATCH 2/9] [SFN] boilerplate changes in preparation to introduce nonbind markers Alexandre Oliva
2017-09-01 1:16 ` [PATCH 6/9] [LVU] Allow final_start_function to skip initial insns Alexandre Oliva
2017-09-01 1:16 ` [PATCH 7/9] [LVU] Introduce location views Alexandre Oliva
2017-09-01 1:16 ` [PATCH 8/9] [IEPM] Introduce debug hook for inline entry point markers Alexandre Oliva
2017-09-01 1:16 ` [PATCH 3/9] [SFN] not-quite-boilerplate changes in preparation to introduce nonbind markers Alexandre Oliva
2017-09-01 1:16 ` [PATCH 4/9] [SFN] introduce statement frontier notes, still disabled Alexandre Oliva
2017-09-01 1:16 ` [PATCH 9/9] [IEPM] Introduce inline entry point markers Alexandre Oliva
2017-09-30 9:04 ` Statement Frontier Notes, Location Views, and Inlined Entry Point Markers Alexandre Oliva
2017-09-30 9:09 ` [PATCH 2/9] [SFN] boilerplate changes in preparation to introduce nonbind markers Alexandre Oliva
2017-10-09 13:02 ` Richard Biener
2017-09-30 9:09 ` [PATCH 5/9] [SFN] Introduce -gstatement-frontiers option, enable debug markers Alexandre Oliva
2017-10-09 13:12 ` Richard Biener
2017-09-30 9:09 ` [PATCH 1/9] [SFN] adjust RTL insn-walking API Alexandre Oliva
2017-10-09 13:24 ` Richard Biener
2017-09-30 9:09 ` [PATCH 6/9] [LVU] Allow final_start_function to skip initial insns Alexandre Oliva
2017-10-19 11:07 ` Richard Biener
2017-10-31 5:10 ` Jeff Law
2017-10-31 5:23 ` Jeff Law
2017-11-01 18:20 ` Alexandre Oliva
2017-11-02 13:00 ` Richard Biener
2017-09-30 9:09 ` [PATCH 4/9] [SFN] introduce statement frontier notes, still disabled Alexandre Oliva
2017-10-09 13:11 ` Richard Biener
2017-10-13 7:25 ` Alexandre Oliva
2017-10-13 9:41 ` Richard Biener
2017-10-17 22:06 ` Alexandre Oliva
2017-10-24 18:11 ` Jason Merrill
2017-11-01 19:14 ` Alexandre Oliva
2017-11-01 19:49 ` Jason Merrill
2017-09-30 9:10 ` [PATCH 3/9] [SFN] not-quite-boilerplate changes in preparation to introduce nonbind markers Alexandre Oliva
2017-10-09 13:07 ` Richard Biener
2017-09-30 9:10 ` [PATCH 8/9] [IEPM] Introduce debug hook for inline entry point markers Alexandre Oliva
2017-10-31 5:58 ` Jeff Law
2017-09-30 9:10 ` [PATCH 9/9] [IEPM] Introduce " Alexandre Oliva
2017-10-31 6:22 ` Jeff Law
2017-11-01 18:36 ` Alexandre Oliva
2017-11-09 16:30 ` Jeff Law
2017-11-10 2:31 ` Alexandre Oliva
2017-09-30 9:10 ` [PATCH 7/9] [LVU] Introduce location views Alexandre Oliva
2017-11-10 2:36 ` SFN+LVU+IEPM v4 (was: Re: Statement Frontier Notes, Location Views, and Inlined Entry Point Markers) Alexandre Oliva
2017-11-10 2:36 ` [SFN+LVU+IEPM v4 5/9] [SFN] introduce statement frontier notes, still disabled Alexandre Oliva
2017-12-07 23:59 ` Jeff Law
2017-12-12 2:41 ` Alexandre Oliva
2017-11-10 2:36 ` [SFN+LVU+IEPM v4 1/9] [SFN] adjust RTL insn-walking API Alexandre Oliva
2017-12-07 22:25 ` Jeff Law
2017-12-12 3:10 ` Alexandre Oliva
2017-12-14 11:55 ` Alexandre Oliva
2017-12-14 12:07 ` Jakub Jelinek
2017-12-14 18:25 ` Alexandre Oliva
2017-11-10 2:36 ` [SFN+LVU+IEPM v4 4/9] [SFN] stabilize find_bb_boundaries Alexandre Oliva
2017-12-07 22:46 ` Jeff Law
2017-12-12 2:38 ` Alexandre Oliva
2017-11-10 2:36 ` [SFN+LVU+IEPM v4 3/9] [SFN] not-quite-boilerplate changes in preparation to introduce nonbind markers Alexandre Oliva
2017-12-07 22:44 ` Jeff Law
2017-12-12 2:31 ` Alexandre Oliva
2017-11-10 2:36 ` [SFN+LVU+IEPM v4 6/9] [SFN] Introduce -gstatement-frontiers option, enable debug markers Alexandre Oliva
2017-12-07 22:49 ` Jeff Law
2017-12-12 2:42 ` Alexandre Oliva
2017-12-12 9:16 ` Christophe Lyon [this message]
2017-12-13 4:22 ` Alexandre Oliva
2018-01-07 17:48 ` H.J. Lu
2017-12-27 8:00 ` [nvptx, committed] Disable -gstatement-frontiers for nvptx Tom de Vries
2017-12-29 4:12 ` Alexandre Oliva
2017-12-29 11:42 ` Tom de Vries
2017-12-31 20:05 ` Alexandre Oliva
2018-01-11 10:12 ` Tom de Vries
2017-11-10 2:36 ` [SFN+LVU+IEPM v4 2/9] [SFN] boilerplate changes in preparation to introduce nonbind markers Alexandre Oliva
2017-12-07 22:27 ` Jeff Law
2017-12-12 2:55 ` Alexandre Oliva
2017-11-10 2:37 ` [SFN+LVU+IEPM v4 8/9] [IEPM] Introduce debug hook for inline entry point markers Alexandre Oliva
2017-12-07 22:51 ` Jeff Law
2017-12-12 2:44 ` Alexandre Oliva
2017-11-10 5:05 ` [SFN+LVU+IEPM v4 7/9] [LVU] Introduce location views Alexandre Oliva
2017-11-13 10:18 ` Richard Biener
2017-11-15 3:59 ` Alexandre Oliva
2017-12-11 23:12 ` Jeff Law
2017-12-12 2:52 ` Alexandre Oliva
2018-01-24 17:36 ` Jakub Jelinek
2018-01-25 20:19 ` Alexandre Oliva
2018-01-26 14:58 ` Jakub Jelinek
2018-01-30 18:40 ` Alexandre Oliva
2018-01-30 22:11 ` Richard Sandiford
2018-02-07 4:14 ` Alexandre Oliva
2018-02-07 7:43 ` Alexandre Oliva
2018-02-06 21:13 ` Jason Merrill
2018-02-07 4:02 ` Alexandre Oliva
2018-02-07 19:23 ` Jason Merrill
2018-02-08 12:56 ` Alexandre Oliva
2018-02-08 16:05 ` Jason Merrill
2018-02-09 3:49 ` Alexandre Oliva
2018-02-07 7:35 ` Alexandre Oliva
2018-02-07 7:36 ` Alexandre Oliva
2018-02-08 19:58 ` Jason Merrill
2018-02-09 3:20 ` Alexandre Oliva
2018-02-11 19:04 ` Andreas Schwab
2018-02-11 20:47 ` Andreas Schwab
2018-02-12 7:46 ` Alexandre Oliva
2018-02-12 7:49 ` Alexandre Oliva
2018-02-12 10:11 ` Andreas Schwab
2018-02-13 5:47 ` Alexandre Oliva
2018-02-14 9:23 ` Andreas Schwab
2017-11-10 5:29 ` [SFN+LVU+IEPM v4 9/9] [IEPM] Introduce inline entry point markers Alexandre Oliva
2017-12-12 2:54 ` Alexandre Oliva
2017-12-21 5:18 ` Jeff Law
2018-01-24 7:11 ` Alexandre Oliva
2018-01-24 17:40 ` Jakub Jelinek
2018-01-25 20:14 ` Alexandre Oliva
2018-02-09 3:21 ` Alexandre Oliva
2018-02-09 3:53 ` Alan Modra
2018-02-09 4:13 ` Jeff Law
2018-02-09 10:35 ` Alexandre Oliva
2018-02-09 12:10 ` Alan Modra
2018-02-09 15:09 ` Jeff Law
2018-02-09 22:52 ` Joseph Myers
2018-02-10 1:36 ` Joseph Myers
2018-02-10 12:35 ` Alexandre Oliva
2018-02-10 18:19 ` Jeff Law
2018-02-11 15:29 ` Alexandre Oliva
2018-02-09 21:01 ` Alexandre Oliva
2018-02-09 23:49 ` Jakub Jelinek
2018-02-10 0:56 ` Alexandre Oliva
2018-02-12 8:08 ` Alexandre Oliva
2018-02-13 13:52 ` Alexandre Oliva
2018-02-13 16:15 ` Jeff Law
2018-02-15 15:23 ` Szabolcs Nagy
2018-02-21 10:12 ` Alexandre Oliva
2018-02-21 12:08 ` Uros Bizjak
2018-02-22 15:22 ` Szabolcs Nagy
2018-02-28 6:17 ` Alexandre Oliva
2018-03-09 9:49 ` Bin.Cheng
2018-03-09 9:55 ` Ramana Radhakrishnan
2018-03-09 11:35 ` Jakub Jelinek
2018-03-07 19:43 ` Jeff Law
2018-02-10 4:39 ` Alexandre Oliva
2018-02-10 6:35 ` Jeff Law
2018-02-10 13:05 ` Alexandre Oliva
2018-02-10 16:36 ` Jeff Law
2018-02-21 10:33 ` Alexandre Oliva
2018-02-26 12:47 ` Richard Biener
2017-11-10 21:31 ` SFN+LVU+IEPM v4 Alexandre Oliva
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='CAKdteOYKnQc7cffdLYOzFyyXFccbhAU=nsnPWgHjuy1DmT1s_Q@mail.gmail.com' \
--to=christophe.lyon@linaro.org \
--cc=aoliva@redhat.com \
--cc=gcc-patches@gcc.gnu.org \
--cc=jason@redhat.com \
--cc=law@redhat.com \
--cc=richard.guenther@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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).