From bfda9a5e8e6cbca41d9a7a64194311a910abc95c Mon Sep 17 00:00:00 2001 From: David Edelsohn Date: Tue, 27 Sep 2016 14:01:41 +0000 Subject: [PATCH] * config/rs6000/rs6000.c (rs6000_output_symbol): Don't modify VAR_DECL string. From-SVN: r240540 --- gcc/ChangeLog | 5 +++++ gcc/config/rs6000/rs6000.c | 5 ++++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index ff35a571469..895cec59142 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2016-09-27 David Edelsohn + + * config/rs6000/rs6000.c (rs6000_output_symbol): Don't modify + VAR_DECL string. + 2016-09-27 Marek Polacek * config/ia64/ia64.c (ia64_print_operand): Adjust fall through diff --git a/gcc/config/rs6000/rs6000.c b/gcc/config/rs6000/rs6000.c index 6897b5c260d..4d3706c370e 100644 --- a/gcc/config/rs6000/rs6000.c +++ b/gcc/config/rs6000/rs6000.c @@ -30309,7 +30309,10 @@ rs6000_output_symbol_ref (FILE *file, rtx x) (TREE_CODE (decl) == FUNCTION_DECL ? "[DS]" : "[UA]"), NULL); - XSTR (x, 0) = name; + + /* Don't modify name in extern VAR_DECL to include mapping class. */ + if (TREE_CODE (decl) == FUNCTION_DECL) + XSTR (x, 0) = name; } if (VTABLE_NAME_P (name)) -- 2.30.2