Re: [PATCH tree-inline] do not say "called from here" with UNKNOWN_LOCATION
On Tue, Sep 22, 2015 at 2:22 AM, Manuel López-Ibáñez wrote: > On 21 September 2015 at 12:29, Richard Biener > wrote: >> On Mon, Sep 21, 2015 at 11:59 AM, Manuel López-Ibáñez >> wrote: >>> On 21 September 2015 at 10:18, Richard Biener >>> wrote: input_location is set from the call stmt: /* FIXME: instantiate_decl isn't called by inlinable_function_p. */ saved_location = input_location; input_location = gimple_location (stmt); it would be nice to get rid of that. >>> >>> I could replace all uses of input_location in this function by >>> gimple_location(stmt) as I noted in the comments. Would that be ok if >>> it works? I'm not sure I can prove that input_location is not used >>> behind the scenes for some other purpose (all the more reason to kill >>> input_location once and for all). Friends, don't let friends use >>> input_location in new code! >> >> Yeah... not sure how to check but to look for any changes in >> generated cc1/cc1plus >> debug info. You could also try making it invalid (-1?) and hope >> libcpp would eventually >> blow up if that is used. >> > > It does blow up with: > > /home/manuel/test2/227965M/build/gcc/gnat1 -gnatwa -quiet -nostdinc > -dumpbase s-mudido.adb -auxbase-strip s-mudido.o -O2 -Wextra -Wall > -fpic -g -gnatpg -mtune=generic -march=x86-64 -gnatO s-mudido.o > s-mudido.adb -o /tmp/ccNQpzNF.s > > at: > > B =>SET_EXPR_LOCATION (mod, EXPR_LOC_OR_LOC (val, input_location)); > > #0 internal_get_tmp_var (val=0x75dfdc40, pre_p=0x7fffdaf0, > post_p=, is_formal=) at > /home/manuel/test2/src/gcc/gimplify.c:540 > #1 0x00c00efd in gimplify_expr > (expr_p=expr_p@entry=0x7fffdaf8, pre_p=pre_p@entry=0x7fffdaf0, > post_p=0x7fffd9a0, post_p@entry=0x0, gimple_test_f= out>, fallback=fallback@entry=1) at > /home/manuel/test2/src/gcc/gimplify.c:9040 > #2 0x00c19b67 in gimple_regimplify_operands > (stmt=0x76074be0, gsi_p=gsi_p@entry=0x7fffdbb0) at > /home/manuel/test2/src/gcc/gimplify-me.c:252 > #3 0x00e8cbe3 in copy_bb (id=id@entry=0x7fffde40, > bb=bb@entry=0x760eb548, > frequency_scale=frequency_scale@entry=1, > count_scale=count_scale@entry=1) at > /home/manuel/test2/src/gcc/tree-inline.c:1798 > #4 0x00e8e039 in copy_cfg_body (new_entry=0x0, > exit_block_map=0x75dff340, entry_block_map=0x760d4c30, > frequency_scale=1, count=, id=0x7fffde40) at > /home/manuel/test2/src/gcc/tree-inline.c:2716 > #5 copy_body (id=0x7fffde40, count=, > frequency_scale=1, entry_block_map=0x760d4c30, > exit_block_map=0x75dff340, new_entry=0x0) at > /home/manuel/test2/src/gcc/tree-inline.c:2955 > #6 0x00e94f71 in expand_call_inline (id=0x7fffde40, > stmt=, bb=) at > /home/manuel/test2/src/gcc/tree-inline.c:4693 > #7 gimple_expand_calls_inline (id=0x7fffde40, bb=) > at /home/manuel/test2/src/gcc/tree-inline.c:4833 > #8 optimize_inline_calls (fn=) at > /home/manuel/test2/src/gcc/tree-inline.c:4973 > #9 0x014c503c in inline_transform (node=0x7644ccf0) at > /home/manuel/test2/src/gcc/ipa-inline-transform.c:545 > #10 0x00d54bac in execute_one_ipa_transform_pass > (ipa_pass=0x2656340, node=0x7644ccf0) at > /home/manuel/test2/src/gcc/passes.c:2197 > #11 execute_all_ipa_transforms () at /home/manuel/test2/src/gcc/passes.c:2238 > #12 0x00a99bc8 in cgraph_node::expand > (this=this@entry=0x7644ccf0) at > /home/manuel/test2/src/gcc/cgraphunit.c:1976 > #13 0x00a9b44e in expand_all_functions () at > /home/manuel/test2/src/gcc/cgraphunit.c:2119 > #14 symbol_table::compile (this=this@entry=0x7642b0a8) at > /home/manuel/test2/src/gcc/cgraphunit.c:2472 > #15 0x00a9da63 in symbol_table::compile (this=0x7642b0a8) > at /home/manuel/test2/src/gcc/cgraphunit.c:2536 > #16 symbol_table::finalize_compilation_unit (this=0x7642b0a8) at > /home/manuel/test2/src/gcc/cgraphunit.c:2562 > #17 0x00e17d90 in compile_file () at > /home/manuel/test2/src/gcc/toplev.c:508 > #18 0x0069e8a4 in do_compile () at > /home/manuel/test2/src/gcc/toplev.c:1973 > #19 toplev::main (this=this@entry=0x7fffe0a0, argc=argc@entry=21, > argv=argv@entry=0x7fffe198) at > /home/manuel/test2/src/gcc/toplev.c:2080 > #20 0x006a0bd7 in main (argc=21, argv=0x7fffe198) at > /home/manuel/test2/src/gcc/main.c:39 > > For some extra reason val does not have a location: > > (gdb) p debug_tree(val) > type type system__multiprocessors__dispatching_domains__create__Tst_ddS__2 type > > sizes-gimplified asm_written nonaliased-component BLK size > unit size iftmp.57> > align 8 symtab -166627696 alias set 32 canonical type > 0x75fca2a0 domain context > dispatching_domains__create__2> > pointer_to_this > reference_to_this chain 0x75fbfc78 system__multiprocessors__dispatching_doma\ > ins__create__Tst_ddS__2>> > asm_written public unsigned DI >
Re: [PATCH tree-inline] do not say "called from here" with UNKNOWN_LOCATION
On 21 September 2015 at 12:29, Richard Biener wrote: > On Mon, Sep 21, 2015 at 11:59 AM, Manuel López-Ibáñez > wrote: >> On 21 September 2015 at 10:18, Richard Biener >> wrote: >>> input_location is set from the call stmt: >>> >>> /* FIXME: instantiate_decl isn't called by inlinable_function_p. */ >>> saved_location = input_location; >>> input_location = gimple_location (stmt); >>> >>> it would be nice to get rid of that. >> >> I could replace all uses of input_location in this function by >> gimple_location(stmt) as I noted in the comments. Would that be ok if >> it works? I'm not sure I can prove that input_location is not used >> behind the scenes for some other purpose (all the more reason to kill >> input_location once and for all). Friends, don't let friends use >> input_location in new code! > > Yeah... not sure how to check but to look for any changes in > generated cc1/cc1plus > debug info. You could also try making it invalid (-1?) and hope > libcpp would eventually > blow up if that is used. > It does blow up with: /home/manuel/test2/227965M/build/gcc/gnat1 -gnatwa -quiet -nostdinc -dumpbase s-mudido.adb -auxbase-strip s-mudido.o -O2 -Wextra -Wall -fpic -g -gnatpg -mtune=generic -march=x86-64 -gnatO s-mudido.o s-mudido.adb -o /tmp/ccNQpzNF.s at: B =>SET_EXPR_LOCATION (mod, EXPR_LOC_OR_LOC (val, input_location)); #0 internal_get_tmp_var (val=0x75dfdc40, pre_p=0x7fffdaf0, post_p=, is_formal=) at /home/manuel/test2/src/gcc/gimplify.c:540 #1 0x00c00efd in gimplify_expr (expr_p=expr_p@entry=0x7fffdaf8, pre_p=pre_p@entry=0x7fffdaf0, post_p=0x7fffd9a0, post_p@entry=0x0, gimple_test_f=, fallback=fallback@entry=1) at /home/manuel/test2/src/gcc/gimplify.c:9040 #2 0x00c19b67 in gimple_regimplify_operands (stmt=0x76074be0, gsi_p=gsi_p@entry=0x7fffdbb0) at /home/manuel/test2/src/gcc/gimplify-me.c:252 #3 0x00e8cbe3 in copy_bb (id=id@entry=0x7fffde40, bb=bb@entry=0x760eb548, frequency_scale=frequency_scale@entry=1, count_scale=count_scale@entry=1) at /home/manuel/test2/src/gcc/tree-inline.c:1798 #4 0x00e8e039 in copy_cfg_body (new_entry=0x0, exit_block_map=0x75dff340, entry_block_map=0x760d4c30, frequency_scale=1, count=, id=0x7fffde40) at /home/manuel/test2/src/gcc/tree-inline.c:2716 #5 copy_body (id=0x7fffde40, count=, frequency_scale=1, entry_block_map=0x760d4c30, exit_block_map=0x75dff340, new_entry=0x0) at /home/manuel/test2/src/gcc/tree-inline.c:2955 #6 0x00e94f71 in expand_call_inline (id=0x7fffde40, stmt=, bb=) at /home/manuel/test2/src/gcc/tree-inline.c:4693 #7 gimple_expand_calls_inline (id=0x7fffde40, bb=) at /home/manuel/test2/src/gcc/tree-inline.c:4833 #8 optimize_inline_calls (fn=) at /home/manuel/test2/src/gcc/tree-inline.c:4973 #9 0x014c503c in inline_transform (node=0x7644ccf0) at /home/manuel/test2/src/gcc/ipa-inline-transform.c:545 #10 0x00d54bac in execute_one_ipa_transform_pass (ipa_pass=0x2656340, node=0x7644ccf0) at /home/manuel/test2/src/gcc/passes.c:2197 #11 execute_all_ipa_transforms () at /home/manuel/test2/src/gcc/passes.c:2238 #12 0x00a99bc8 in cgraph_node::expand (this=this@entry=0x7644ccf0) at /home/manuel/test2/src/gcc/cgraphunit.c:1976 #13 0x00a9b44e in expand_all_functions () at /home/manuel/test2/src/gcc/cgraphunit.c:2119 #14 symbol_table::compile (this=this@entry=0x7642b0a8) at /home/manuel/test2/src/gcc/cgraphunit.c:2472 #15 0x00a9da63 in symbol_table::compile (this=0x7642b0a8) at /home/manuel/test2/src/gcc/cgraphunit.c:2536 #16 symbol_table::finalize_compilation_unit (this=0x7642b0a8) at /home/manuel/test2/src/gcc/cgraphunit.c:2562 #17 0x00e17d90 in compile_file () at /home/manuel/test2/src/gcc/toplev.c:508 #18 0x0069e8a4 in do_compile () at /home/manuel/test2/src/gcc/toplev.c:1973 #19 toplev::main (this=this@entry=0x7fffe0a0, argc=argc@entry=21, argv=argv@entry=0x7fffe198) at /home/manuel/test2/src/gcc/toplev.c:2080 #20 0x006a0bd7 in main (argc=21, argv=0x7fffe198) at /home/manuel/test2/src/gcc/main.c:39 For some extra reason val does not have a location: (gdb) p debug_tree(val) sizes-gimplified asm_written nonaliased-component BLK size unit size align 8 symtab -166627696 alias set 32 canonical type 0x75fca2a0 domain context pointer_to_this reference_to_this chain > asm_written public unsigned DI size unit size align 64 symtab -166626736 alias set 41 canonical type 0x75fca540> arg 0 nothrow arg 0 visited var def_stmt R.94_159 = .builtin_alloca_with_align (iftmp.93_10, 8); version 159 ptr-info 0x75d7d5a0> arg 1 s-mudido.adb:156:24>> Arguably, gimple_location (stmt) is probably better than anything that may be initially at input_location. Then, we cannot remov
Re: [PATCH tree-inline] do not say "called from here" with UNKNOWN_LOCATION
On Mon, Sep 21, 2015 at 12:29:36PM +0200, Richard Biener wrote: > On Mon, Sep 21, 2015 at 11:59 AM, Manuel López-Ibáñez > wrote: > > On 21 September 2015 at 10:18, Richard Biener > > wrote: > >> input_location is set from the call stmt: > >> > >> /* FIXME: instantiate_decl isn't called by inlinable_function_p. */ > >> saved_location = input_location; > >> input_location = gimple_location (stmt); > >> > >> it would be nice to get rid of that. > > > > I could replace all uses of input_location in this function by > > gimple_location(stmt) as I noted in the comments. Would that be ok if > > it works? I'm not sure I can prove that input_location is not used > > behind the scenes for some other purpose (all the more reason to kill > > input_location once and for all). Friends, don't let friends use > > input_location in new code! > > Yeah... not sure how to check but to look for any changes in > generated cc1/cc1plus > debug info. You could also try making it invalid (-1?) and hope > libcpp would eventually > blow up if that is used. I've been kind of meaning to add some raii classes like auto_assert_no_input_location that assert if you use input_location while its on the stack. It shouldn't be that hard to do, so it'd be cool if someone beat me to getting it done :) Trev
Re: [PATCH tree-inline] do not say "called from here" with UNKNOWN_LOCATION
On Mon, Sep 21, 2015 at 12:46 PM, Manuel López-Ibáñez wrote: > On 21 September 2015 at 12:29, Richard Biener > wrote: least note the function we are failing to inline to (thus, use DECL_SOURCE_LOCATION of cfun->decl). So better add a diag_location and compute that upfront to avoid repeating the check. >>> >>>error ("inlining failed in call to always_inline %q+F: %s", fn, >>> cgraph_inline_failed_string (reason)); >>> >>> The call is using '+F', thus the location is set to some location >>> related to F, depending on which *_printer function is active at that >>> moment. cp_printer uses location_of, and default_tree_printer uses >>> DECL_SOURCE_LOCATION. Is the default_tree_printer always used at this >>> point? If yes, I completely agree we should use an explicit >>> DECL_SOURCE_LOCATION. The meaning of '+' is not only opaque but it >>> breaks #pragma GCC diagnostic. >> >> But it prints the location of the function we failed to inline. I >> want to retain >> at least an approximation to the location of the call, which is the location >> of the function we inline _to_. > > I think I misunderstood you. Do you mean something like? > > if (gimple_location (stmt) != UNKNOWN_LOCATION) > inform (gimple_location (stmt), "called from here"); > else > inform (DECL_SOURCE_LOCATION (cfun->decl), "called from this > function"); Yes. (now that location may also be UNKNOWN in which case I don't have a good fallback idea and we can drop the note) Richard. > > Cheers, > > Manuel.
Re: [PATCH tree-inline] do not say "called from here" with UNKNOWN_LOCATION
On 21 September 2015 at 12:29, Richard Biener wrote: >>> least note the function we are failing to inline to (thus, use >>> DECL_SOURCE_LOCATION >>> of cfun->decl). So better add a diag_location and compute that upfront to >>> avoid >>> repeating the check. >> >>error ("inlining failed in call to always_inline %q+F: %s", fn, >> cgraph_inline_failed_string (reason)); >> >> The call is using '+F', thus the location is set to some location >> related to F, depending on which *_printer function is active at that >> moment. cp_printer uses location_of, and default_tree_printer uses >> DECL_SOURCE_LOCATION. Is the default_tree_printer always used at this >> point? If yes, I completely agree we should use an explicit >> DECL_SOURCE_LOCATION. The meaning of '+' is not only opaque but it >> breaks #pragma GCC diagnostic. > > But it prints the location of the function we failed to inline. I > want to retain > at least an approximation to the location of the call, which is the location > of the function we inline _to_. I think I misunderstood you. Do you mean something like? if (gimple_location (stmt) != UNKNOWN_LOCATION) inform (gimple_location (stmt), "called from here"); else inform (DECL_SOURCE_LOCATION (cfun->decl), "called from this function"); Cheers, Manuel.
Re: [PATCH tree-inline] do not say "called from here" with UNKNOWN_LOCATION
On Mon, Sep 21, 2015 at 11:59 AM, Manuel López-Ibáñez wrote: > On 21 September 2015 at 10:18, Richard Biener > wrote: >> input_location is set from the call stmt: >> >> /* FIXME: instantiate_decl isn't called by inlinable_function_p. */ >> saved_location = input_location; >> input_location = gimple_location (stmt); >> >> it would be nice to get rid of that. > > I could replace all uses of input_location in this function by > gimple_location(stmt) as I noted in the comments. Would that be ok if > it works? I'm not sure I can prove that input_location is not used > behind the scenes for some other purpose (all the more reason to kill > input_location once and for all). Friends, don't let friends use > input_location in new code! Yeah... not sure how to check but to look for any changes in generated cc1/cc1plus debug info. You could also try making it invalid (-1?) and hope libcpp would eventually blow up if that is used. >> If the call is artificially generated it might have no location so I >> think the assert >> is bogus. Also in the case of UNKNOWN_LOCATION it would be nice to at > > I was sure of that, but I was also surprised that not a single > testcase was triggering it. I can re-submit without the assert. please >> least note the function we are failing to inline to (thus, use >> DECL_SOURCE_LOCATION >> of cfun->decl). So better add a diag_location and compute that upfront to >> avoid >> repeating the check. > >error ("inlining failed in call to always_inline %q+F: %s", fn, > cgraph_inline_failed_string (reason)); > > The call is using '+F', thus the location is set to some location > related to F, depending on which *_printer function is active at that > moment. cp_printer uses location_of, and default_tree_printer uses > DECL_SOURCE_LOCATION. Is the default_tree_printer always used at this > point? If yes, I completely agree we should use an explicit > DECL_SOURCE_LOCATION. The meaning of '+' is not only opaque but it > breaks #pragma GCC diagnostic. But it prints the location of the function we failed to inline. I want to retain at least an approximation to the location of the call, which is the location of the function we inline _to_. > >> Did you investigate the glibc case on whether caller or callee are >> artificial? > > No, I could not get glibc to compile. Unfortunately, the machine of > the compile farm that I use to work on GCC is too old. Installing > locally all up-to-date dependencies would require too much time from > me that is better spent on other things. Nevertheless, printing "cc1: > called from here" is always bogus. Not printing it is better. If we > could print something smarter, that would be perfect, but I don't know > how to do that, so "better" is good enough for me. Would you agree? Well, it's easy to do better, see above. Richard. > Cheers, > > Manuel.
Re: [PATCH tree-inline] do not say "called from here" with UNKNOWN_LOCATION
On 21 September 2015 at 10:18, Richard Biener wrote: > input_location is set from the call stmt: > > /* FIXME: instantiate_decl isn't called by inlinable_function_p. */ > saved_location = input_location; > input_location = gimple_location (stmt); > > it would be nice to get rid of that. I could replace all uses of input_location in this function by gimple_location(stmt) as I noted in the comments. Would that be ok if it works? I'm not sure I can prove that input_location is not used behind the scenes for some other purpose (all the more reason to kill input_location once and for all). Friends, don't let friends use input_location in new code! > If the call is artificially generated it might have no location so I > think the assert > is bogus. Also in the case of UNKNOWN_LOCATION it would be nice to at I was sure of that, but I was also surprised that not a single testcase was triggering it. I can re-submit without the assert. > least note the function we are failing to inline to (thus, use > DECL_SOURCE_LOCATION > of cfun->decl). So better add a diag_location and compute that upfront to > avoid > repeating the check. error ("inlining failed in call to always_inline %q+F: %s", fn, cgraph_inline_failed_string (reason)); The call is using '+F', thus the location is set to some location related to F, depending on which *_printer function is active at that moment. cp_printer uses location_of, and default_tree_printer uses DECL_SOURCE_LOCATION. Is the default_tree_printer always used at this point? If yes, I completely agree we should use an explicit DECL_SOURCE_LOCATION. The meaning of '+' is not only opaque but it breaks #pragma GCC diagnostic. > Did you investigate the glibc case on whether caller or callee are artificial? No, I could not get glibc to compile. Unfortunately, the machine of the compile farm that I use to work on GCC is too old. Installing locally all up-to-date dependencies would require too much time from me that is better spent on other things. Nevertheless, printing "cc1: called from here" is always bogus. Not printing it is better. If we could print something smarter, that would be perfect, but I don't know how to do that, so "better" is good enough for me. Would you agree? Cheers, Manuel.
Re: [PATCH tree-inline] do not say "called from here" with UNKNOWN_LOCATION
On Fri, Sep 18, 2015 at 8:47 PM, Manuel López-Ibáñez wrote: > And now with the patch. > > On 18 September 2015 at 20:40, Manuel López-Ibáñez > wrote: >> In https://sourceware.org/ml/libc-alpha/2014-12/msg00300.html, we give a >> "called from here" note without actually having a location, which looks >> strange. I haven't been able to generate such a testcase. In this patch, we >> assert this cannot happen when checking and simply skip the extra note in >> release mode. >> >> Boot&tested on x86_64-linux-gnu >> >> OK? Hmm. input_location is set from the call stmt: /* FIXME: instantiate_decl isn't called by inlinable_function_p. */ saved_location = input_location; input_location = gimple_location (stmt); it would be nice to get rid of that. If the call is artificially generated it might have no location so I think the assert is bogus. Also in the case of UNKNOWN_LOCATION it would be nice to at least note the function we are failing to inline to (thus, use DECL_SOURCE_LOCATION of cfun->decl). So better add a diag_location and compute that upfront to avoid repeating the check. Did you investigate the glibc case on whether caller or callee are artificial? Richard. >> >> gcc/testsuite/ChangeLog: >> >> 2015-09-18 Manuel López-Ibáñez >> >> * gcc.target/i386/inline_error.c (int bar): Use dg-message for note. >> * gcc.target/i386/pr57756.c (static __inline int caller): Likewise. >> * gcc.target/i386/pr59789.c (f1): Likewise. >> * gcc.target/i386/intrinsics_5.c (__m128i foo): Likewise. >> * gcc.target/i386/intrinsics_6.c: Likewise. >> * gcc.dg/winline-5.c (int t): Likewise. >> * gcc.dg/winline-9.c (t): Likewise. >> * gcc.dg/always_inline2.c (q): Likewise. >> * gcc.dg/winline-2.c (inline int t): Likewise. >> * gcc.dg/winline-6.c: Likewise. >> * gcc.dg/winline-10.c (void g): Likewise. >> * gcc.dg/pr49243.c (void parse): Likewise. >> * gcc.dg/always_inline3.c (q2): Likewise. >> * gcc.dg/winline-3.c: Likewise. >> * gcc.dg/winline-7.c (inline void *t): Likewise. >> >> gcc/ChangeLog: >> >> 2015-09-18 Manuel López-Ibáñez >> >> * tree-inline.c (expand_call_inline): Use inform for extra note. >> Do not give "called from here" with UNKNOWN_LOCATION.
[PATCH tree-inline] do not say "called from here" with UNKNOWN_LOCATION
In https://sourceware.org/ml/libc-alpha/2014-12/msg00300.html, we give a "called from here" note without actually having a location, which looks strange. I haven't been able to generate such a testcase. In this patch, we assert this cannot happen when checking and simply skip the extra note in release mode. Boot&tested on x86_64-linux-gnu OK? gcc/testsuite/ChangeLog: 2015-09-18 Manuel López-Ibáñez * gcc.target/i386/inline_error.c (int bar): Use dg-message for note. * gcc.target/i386/pr57756.c (static __inline int caller): Likewise. * gcc.target/i386/pr59789.c (f1): Likewise. * gcc.target/i386/intrinsics_5.c (__m128i foo): Likewise. * gcc.target/i386/intrinsics_6.c: Likewise. * gcc.dg/winline-5.c (int t): Likewise. * gcc.dg/winline-9.c (t): Likewise. * gcc.dg/always_inline2.c (q): Likewise. * gcc.dg/winline-2.c (inline int t): Likewise. * gcc.dg/winline-6.c: Likewise. * gcc.dg/winline-10.c (void g): Likewise. * gcc.dg/pr49243.c (void parse): Likewise. * gcc.dg/always_inline3.c (q2): Likewise. * gcc.dg/winline-3.c: Likewise. * gcc.dg/winline-7.c (inline void *t): Likewise. gcc/ChangeLog: 2015-09-18 Manuel López-Ibáñez * tree-inline.c (expand_call_inline): Use inform for extra note. Do not give "called from here" with UNKNOWN_LOCATION.
Re: [PATCH tree-inline] do not say "called from here" with UNKNOWN_LOCATION
And now with the patch. On 18 September 2015 at 20:40, Manuel López-Ibáñez wrote: > In https://sourceware.org/ml/libc-alpha/2014-12/msg00300.html, we give a > "called from here" note without actually having a location, which looks > strange. I haven't been able to generate such a testcase. In this patch, we > assert this cannot happen when checking and simply skip the extra note in > release mode. > > Boot&tested on x86_64-linux-gnu > > OK? > > > gcc/testsuite/ChangeLog: > > 2015-09-18 Manuel López-Ibáñez > > * gcc.target/i386/inline_error.c (int bar): Use dg-message for note. > * gcc.target/i386/pr57756.c (static __inline int caller): Likewise. > * gcc.target/i386/pr59789.c (f1): Likewise. > * gcc.target/i386/intrinsics_5.c (__m128i foo): Likewise. > * gcc.target/i386/intrinsics_6.c: Likewise. > * gcc.dg/winline-5.c (int t): Likewise. > * gcc.dg/winline-9.c (t): Likewise. > * gcc.dg/always_inline2.c (q): Likewise. > * gcc.dg/winline-2.c (inline int t): Likewise. > * gcc.dg/winline-6.c: Likewise. > * gcc.dg/winline-10.c (void g): Likewise. > * gcc.dg/pr49243.c (void parse): Likewise. > * gcc.dg/always_inline3.c (q2): Likewise. > * gcc.dg/winline-3.c: Likewise. > * gcc.dg/winline-7.c (inline void *t): Likewise. > > gcc/ChangeLog: > > 2015-09-18 Manuel López-Ibáñez > > * tree-inline.c (expand_call_inline): Use inform for extra note. > Do not give "called from here" with UNKNOWN_LOCATION. Index: gcc/testsuite/gcc.target/i386/inline_error.c === --- gcc/testsuite/gcc.target/i386/inline_error.c(revision 227880) +++ gcc/testsuite/gcc.target/i386/inline_error.c(working copy) @@ -7,7 +7,7 @@ foo () /* { dg-error "inlining failed in return 0; } int bar() { - return foo (); /* { dg-error "called from here" } */ + return foo (); /* { dg-message "called from here" } */ } Index: gcc/testsuite/gcc.target/i386/pr57756.c === --- gcc/testsuite/gcc.target/i386/pr57756.c (revision 227880) +++ gcc/testsuite/gcc.target/i386/pr57756.c (working copy) @@ -9,11 +9,11 @@ __inline int callee () /* { dg-error "in } __attribute__((target("sse"))) static __inline int caller () { - return callee(); /* { dg-error "called from here" } */ + return callee(); /* { dg-message "called from here" } */ } int main () { return caller(); Index: gcc/testsuite/gcc.target/i386/pr59789.c === --- gcc/testsuite/gcc.target/i386/pr59789.c (revision 227880) +++ gcc/testsuite/gcc.target/i386/pr59789.c (working copy) @@ -16,7 +16,7 @@ _mm_set_epi32 (int __q3, int __q2, int _ __m128i f1(void) { /* { dg-message "warning: SSE vector return without SSE enabled changes the ABI" } */ - return _mm_set_epi32 (0, 0, 0, 0); /* { dg-error "called from here" } */ + return _mm_set_epi32 (0, 0, 0, 0); /* { dg-message "called from here" } */ } Index: gcc/testsuite/gcc.target/i386/intrinsics_5.c === --- gcc/testsuite/gcc.target/i386/intrinsics_5.c(revision 227880) +++ gcc/testsuite/gcc.target/i386/intrinsics_5.c(working copy) @@ -8,9 +8,9 @@ #include __m128i foo(__m128i *V) { -return _mm_stream_load_si128(V); /* { dg-error "called from here" } */ +return _mm_stream_load_si128(V); /* { dg-message "called from here" } */ } /* { dg-prune-output ".*inlining failed.*" } */ Index: gcc/testsuite/gcc.target/i386/intrinsics_6.c === --- gcc/testsuite/gcc.target/i386/intrinsics_6.c(revision 227880) +++ gcc/testsuite/gcc.target/i386/intrinsics_6.c(working copy) @@ -8,9 +8,9 @@ #include __m128i foo(__m128i *V) { -return _mm_stream_load_si128(V); /* { dg-error "called from here" } */ +return _mm_stream_load_si128(V); /* { dg-message "called from here" } */ } /* { dg-prune-output ".*inlining failed.*" } */ Index: gcc/testsuite/gcc.dg/winline-5.c === --- gcc/testsuite/gcc.dg/winline-5.c(revision 227880) +++ gcc/testsuite/gcc.dg/winline-5.c(working copy) @@ -15,7 +15,7 @@ inline int q(void) /* { dg-warning "inli big(); big(); } int t (void) { - return q (); /* { dg-warning "called from here" } */ + return q (); /* { dg-message "called from here" } */ } Index: gcc/testsuite/gcc.dg/winline-9.c === --- gcc/testsuite/gcc.dg/winline-9.c(revision 227880) +++ gcc/testsuite/gcc.dg/winline-9.c(working copy) @@ -20,7 +20,7 @@ int t() { if (a) aa(); if (b) -bb(); /* { dg-warning "called from here" "" } */ +bb(); /