Re: [PATCH] gcc/final.c: -fdebug-prefix-map support to remap sources with relative path

2016-03-30 Thread Hongxu Jia
On 03/31/2016 01:58 AM, Joseph Myers wrote: On Sun, 27 Mar 2016, Hongxu Jia wrote: PR other/70428 * final.c (remap_debug_filename): Use lrealpath to translate relative path before remapping I think this would break cases that currently work. When using -fdebug-prefix-map you should

[PATCH] gcc/final.c: -fdebug-prefix-map support to remap sources with relative path

2016-03-27 Thread Hongxu Jia
PR other/70428 * final.c (remap_debug_filename): Use lrealpath to translate relative path before remapping Signed-off-by: Hongxu Jia <hongxu@windriver.com> --- gcc/ChangeLog | 6 ++ gcc/final.c | 15 --- 2 files changed, 18 insertions(+), 3 deletions(-) diff --git

Re: [PATCH V3]PR other/70268: map one directory name (old) to another (new) in __FILE__

2016-03-23 Thread Hongxu Jia
Ping, is that OK? Any suggestions? //Hongxu On 03/18/2016 01:16 PM, Hongxu Jia wrote: Changed in V3: - Rebase to latest master (efc86c4c627b82364f118a29b5d9d58cad8b8c76) - Fix bad formatting (missing space before '('). - Use of @code{} around literal source code text. //Hongxu

Re: [PATCH]PR other/70268: map one directory name (old) to another (new) in __FILE__

2016-03-20 Thread Hongxu Jia
On 03/18/2016 06:43 AM, Joseph Myers wrote: On Thu, 17 Mar 2016, Hongxu Jia wrote: + if (add_file_prefix_map(arg) < 0) + if (add_file_prefix_map (arg) < 0) I will correct them in V3. Bad formatting (missing space before '('). Likewise elsewhere in this patch. +@item

Re: [PATCH V3]PR other/70268: map one directory name (old) to another (new) in __FILE__

2016-03-19 Thread Hongxu Jia
On 03/18/2016 03:56 PM, Bernhard Reutner-Fischer wrote: On March 18, 2016 6:16:46 AM GMT+01:00, Hongxu Jia <hongxu@windriver.com> wrote: +/* Perform user-specified mapping of __FILE__ prefixes. Return + the new name corresponding to filename. */ + +const char * +remap_file_fi

[PATCH]PR other/70268: map one directory name (old) to another (new) in __FILE__

2016-03-19 Thread Hongxu Jia
(-ffile-prefix-map): Document. Signed-off-by: Hongxu Jia <hongxu@windriver.com> --- gcc/ChangeLog | 9 + gcc/c-family/c-opts.c | 6 gcc/c-family/c.opt| 4 +++ gcc/doc/invoke.texi | 6 gcc/dwarf2out.c | 1 + gcc/gimplify.c

Re: [PATCH V3]PR other/70268: map one directory name (old) to another (new) in __FILE__

2016-03-19 Thread Hongxu Jia
On 03/18/2016 04:05 PM, Hongxu Jia wrote: Please explain why you first alloca() and then strdup the result instead of XNEWVEC BTW, I just refer the implement of -fdebug-prefix-map: In gcc/final.c const char * remap_debug_filename (const char *filename

[PATCH V2]PR other/70268: map one directory name (old) to another (new) in __FILE__

2016-03-19 Thread Hongxu Jia
Changed in V2: - Rebase to latest master (f958b9e9d4dfed811f36217c800194dd82becf01) - Fix incorrect PR in libcpp/ChangeLog and gcc/ChangeLog //Hongxu >From b8761da98466242e1d18b4e39eb0ea3c6cee4d73 Mon Sep 17 00:00:00 2001 From: Hongxu Jia <hongxu@windriver.com> Date: Wed, 16 Mar 2

[PATCH V3]PR other/70268: map one directory name (old) to another (new) in __FILE__

2016-03-18 Thread Hongxu Jia
Changed in V3: - Rebase to latest master (efc86c4c627b82364f118a29b5d9d58cad8b8c76) - Fix bad formatting (missing space before '('). - Use of @code{} around literal source code text. //Hongxu >From 7fe014845596f547d735324c466799d8207d282d Mon Sep 17 00:00:00 2001 From: Hongxu Jia <

Re: [PATCH PR69821] gcc: add option gno-record-debug-prefix-map

2016-02-15 Thread Hongxu Jia
On 02/15/2016 04:09 PM, Hongxu Jia wrote: PR other/69821 * common.opt (grecord-debug-prefix-map, gno-record-debug-prefix-map): New options. * dwarf2out.c:(gen_producer_string) Use option to filter -fdebug-prefix-map * doc/invoke.texi: Document -grecord-debug-prefix-map

[PATCH PR69821] gcc: add option gno-record-debug-prefix-map

2016-02-15 Thread Hongxu Jia
-by: Hongxu Jia <hongxu@windriver.com> --- gcc/common.opt | 8 gcc/doc/invoke.texi | 14 ++ gcc/dwarf2out.c | 8 3 files changed, 30 insertions(+) diff --git a/gcc/common.opt b/gcc/common.opt index 2259f29..3aef05a 100644 --- a/gcc/common.opt +++

[PATCH V3] [gcc-4.10] gcc/Makefile.in: fix parallel building failure

2014-07-25 Thread Hongxu Jia
did (which also is part of gengtype). [GCC #61899] https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61899 Signed-off-by: Hongxu Jia hongxu@windriver.com --- gcc/Makefile.in | 7 ++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/gcc/Makefile.in b/gcc/Makefile.in index a726109

Re: [PATCH][gcc-4.9.0] gcc/Makefile.in: fix parallel building failure

2014-07-24 Thread Hongxu Jia
On 07/24/2014 12:17 PM, Andrew Pinski wrote: On Wed, Jul 23, 2014 at 9:10 PM, Hongxu Jia hongxu@windriver.com wrote: 1. How to reproduce the issue: 1) manually modify gcc/Makefile.in to delay the generation of config.h: ... diff --git gcc-4.9.0/gcc/Makefile.in gcc-4.9.0/gcc/Makefile.in

[PATCH][gcc-4.10] gcc/Makefile.in: add missing errors.o/gcc-ar.o/gcc-nm.o/gcc-ranlib.o to OBJS

2014-07-24 Thread Hongxu Jia
failure 2. Analysis While parallel make, the '$(ALL_HOST_OBJS) : | $(generated_files)' rule doesn't work for these missing objects. And there was potential compile failure. [GCC #61899] https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61899 Signed-off-by: Hongxu Jia hongxu@windriver.com --- gcc

Re: [PATCH][gcc-4.10] gcc/Makefile.in: add missing errors.o/gcc-ar.o/gcc-nm.o/gcc-ranlib.o to OBJS

2014-07-24 Thread Hongxu Jia
I am afraid adding these to OBJS is incorrect, it will cause other build error. Please ignore this patch, V3 incoming. //Hongxu On 07/25/2014 11:14 AM, Hongxu Jia wrote: 1. Reproduce steps 1) Manually modify gcc/Makefile.in to delay the generation of config.h: ... diff --git a/gcc

[PATCH][gcc-4.9.0] gcc/Makefile.in: fix parallel building failure

2014-07-23 Thread Hongxu Jia
'%.o : %.c' rule doesn't override 'build/%.o :'. For more detail: https://bugzilla.yoctoproject.org/show_bug.cgi?id=6568 Signed-off-by: Hongxu Jia hongxu@windriver.com --- gcc/Makefile.in | 12 1 file changed, 8 insertions(+), 4 deletions(-) diff --git gcc-4.9.0/gcc/Makefile.in