Commit 60591d4e by Richard Biener Committed by Richard Biener

function.c (fndecl_name): Use verbosity 1 (no arguments) for lang_hooks.decl_printable_name.

2017-08-23  Richard Biener  <rguenther@suse.de>

	* function.c (fndecl_name): Use verbosity 1 (no arguments) for
	lang_hooks.decl_printable_name.
	* print-rtl-function.c (print_rtx_function): Likewise.
	* tree-pretty-print.c (dump_function_header): Likewise.

	* g++.dg/cpp1y/constexpr-instantiate.C: Adjust.
	* g++.dg/tree-ssa/pr45605.C: Likewise.
	* gnat.dg/noinline2.ad: Likewise.b
	* gnat.dg/renaming6.ad: Likewise.b
	* gnat.dg/renaming6.ad: Likewise.s
	* gnat.dg/specs/noinline3.ad: Likewise.s

From-SVN: r251308
parent 3767b2e4
2017-08-23 Richard Biener <rguenther@suse.de> 2017-08-23 Richard Biener <rguenther@suse.de>
* function.c (fndecl_name): Use verbosity 1 (no arguments) for
lang_hooks.decl_printable_name.
* print-rtl-function.c (print_rtx_function): Likewise.
* tree-pretty-print.c (dump_function_header): Likewise.
2017-08-23 Richard Biener <rguenther@suse.de>
PR lto/81940 PR lto/81940
* dwarf2out.c (dwarf2out_abstract_function): Handle LTO with * dwarf2out.c (dwarf2out_abstract_function): Handle LTO with
-g0 at compile-time. -g0 at compile-time.
......
...@@ -6259,7 +6259,7 @@ fndecl_name (tree fndecl) ...@@ -6259,7 +6259,7 @@ fndecl_name (tree fndecl)
{ {
if (fndecl == NULL) if (fndecl == NULL)
return "(nofn)"; return "(nofn)";
return lang_hooks.decl_printable_name (fndecl, 2); return lang_hooks.decl_printable_name (fndecl, 1);
} }
/* Returns the name of function FN. */ /* Returns the name of function FN. */
......
...@@ -227,7 +227,7 @@ print_rtx_function (FILE *outfile, function *fn, bool compact) ...@@ -227,7 +227,7 @@ print_rtx_function (FILE *outfile, function *fn, bool compact)
tree fdecl = fn->decl; tree fdecl = fn->decl;
const char *dname = lang_hooks.decl_printable_name (fdecl, 2); const char *dname = lang_hooks.decl_printable_name (fdecl, 1);
fprintf (outfile, "(function \"%s\"\n", dname); fprintf (outfile, "(function \"%s\"\n", dname);
......
2017-08-23 Richard Biener <rguenther@suse.de> 2017-08-23 Richard Biener <rguenther@suse.de>
* g++.dg/cpp1y/constexpr-instantiate.C: Adjust.
* g++.dg/tree-ssa/pr45605.C: Likewise.
* gnat.dg/noinline2.ad: Likewise.b
* gnat.dg/renaming6.ad: Likewise.b
* gnat.dg/renaming6.ad: Likewise.s
* gnat.dg/specs/noinline3.ad: Likewise.s
2017-08-23 Richard Biener <rguenther@suse.de>
PR lto/81940 PR lto/81940
* g++.dg/lto/pr81940_0.C: New testcase. * g++.dg/lto/pr81940_0.C: New testcase.
......
...@@ -17,5 +17,5 @@ bool g (int x) { return f (x); } ...@@ -17,5 +17,5 @@ bool g (int x) { return f (x); }
template bool f<int>(int); template bool f<int>(int);
// Verify that the defintions of both f() and g() are emitted. // Verify that the defintions of both f() and g() are emitted.
// { dg-final { scan-tree-dump-times "\nconstexpr bool f\\\(" 1 "optimized" } } // { dg-final { scan-tree-dump-times ";; Function f" 1 "optimized" } }
// { dg-final { scan-tree-dump-times "\nbool g\\\(" 1 "optimized" } } // { dg-final { scan-tree-dump-times ";; Function g" 1 "optimized" } }
...@@ -37,4 +37,4 @@ int main() { ...@@ -37,4 +37,4 @@ int main() {
/* We should devirtualize call to D::Run */ /* We should devirtualize call to D::Run */
/* { dg-final { scan-tree-dump-times "D::Run \\(" 1 "fre1" } } */ /* { dg-final { scan-tree-dump-times "D::Run \\(" 3 "fre1" } } */
...@@ -18,4 +18,4 @@ package body Noinline2 is ...@@ -18,4 +18,4 @@ package body Noinline2 is
end Noinline2; end Noinline2;
-- { dg-final { scan-tree-dump-times "noinline2.inner" 2 "optimized" } } -- { dg-final { scan-tree-dump-times "noinline2.inner" 4 "optimized" } }
...@@ -15,16 +15,16 @@ package body Renaming6 is ...@@ -15,16 +15,16 @@ package body Renaming6 is
function Get_J return Integer is function Get_J return Integer is
begin begin
return J; return X;
end; end;
procedure Set_J (Val : Integer) is procedure Set_J (Val : Integer) is
begin begin
J := Val; X := Val;
end; end;
end Renaming6; end Renaming6;
-- { dg-final { scan-tree-dump-times "atomic_load" 2 "original" } } -- { dg-final { scan-tree-dump-times "atomic_load" 2 "original" } }
-- { dg-final { scan-tree-dump-times "atomic_store" 2 "original" } } -- { dg-final { scan-tree-dump-times "atomic_store" 2 "original" } }
-- { dg-final { scan-tree-dump-not "j" "original" } } -- { dg-final { scan-tree-dump-not "x" "original" } }
...@@ -6,7 +6,7 @@ package Renaming6 is ...@@ -6,7 +6,7 @@ package Renaming6 is
function Get_I return Integer; function Get_I return Integer;
procedure Set_I (Val : Integer); procedure Set_I (Val : Integer);
J : Integer renames I; X : Integer renames I;
function Get_J return Integer; function Get_J return Integer;
procedure Set_J (Val : Integer); procedure Set_J (Val : Integer);
......
...@@ -5,4 +5,4 @@ with Noinline3_Pkg; ...@@ -5,4 +5,4 @@ with Noinline3_Pkg;
package Noinline3 is new Noinline3_Pkg (0); package Noinline3 is new Noinline3_Pkg (0);
-- { dg-final { scan-tree-dump-times "noinline3.inner" 2 "optimized" } } -- { dg-final { scan-tree-dump-times "noinline3.inner" 4 "optimized" } }
...@@ -4047,7 +4047,7 @@ dump_function_header (FILE *dump_file, tree fdecl, dump_flags_t flags) ...@@ -4047,7 +4047,7 @@ dump_function_header (FILE *dump_file, tree fdecl, dump_flags_t flags)
struct cgraph_node *node = cgraph_node::get (fdecl); struct cgraph_node *node = cgraph_node::get (fdecl);
struct function *fun = DECL_STRUCT_FUNCTION (fdecl); struct function *fun = DECL_STRUCT_FUNCTION (fdecl);
dname = lang_hooks.decl_printable_name (fdecl, 2); dname = lang_hooks.decl_printable_name (fdecl, 1);
if (DECL_ASSEMBLER_NAME_SET_P (fdecl)) if (DECL_ASSEMBLER_NAME_SET_P (fdecl))
aname = (IDENTIFIER_POINTER aname = (IDENTIFIER_POINTER
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment