2017-07-03 Dominique d'Humieres <dominiq@lps.ens.fr>
PR target/81033
* config/darwin.c (darwin_function_switched_text_sections):
Replace DECL_NAME with DECL_ASSEMBLER_NAME, split assemble_name_raw
in two pieces, and suppress the use of buf.
From-SVN: r249926
+2017-07-03 Dominique d'Humieres <dominiq@lps.ens.fr>
+
+ PR target/81033
+ * config/darwin.c (darwin_function_switched_text_sections):
+ Replace DECL_NAME with DECL_ASSEMBLER_NAME, split assemble_name_raw
+ in two pieces, and suppress the use of buf.
+
2017-07-03 Nathan Sidwell <nathan@acm.org>
* hash-table.h (hash_table_mod1): Fix indentation.
void
darwin_function_switched_text_sections (FILE *fp, tree decl, bool new_is_cold)
{
- char buf[128];
- snprintf (buf, 128, "%s%s",new_is_cold?"__cold_sect_of_":"__hot_sect_of_",
- IDENTIFIER_POINTER (DECL_NAME (decl)));
/* Make sure we pick up all the relevant quotes etc. */
- assemble_name_raw (fp, (const char *) buf);
+ assemble_name_raw (fp, new_is_cold?"__cold_sect_of_":"__hot_sect_of_");
+ assemble_name_raw (fp, IDENTIFIER_POINTER (DECL_ASSEMBLER_NAME (decl)));
fputs (":\n", fp);
}