From: David Edelsohn Date: Wed, 2 Jun 2021 17:32:45 +0000 (-0400) Subject: aix: Use assemble_name to output BSS section name. X-Git-Tag: basepoints/gcc-13~7064 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=03d921abe60fe9ff54a3c449eff1531e73a19215;p=thirdparty%2Fgcc.git aix: Use assemble_name to output BSS section name. The code to emit BSS CSECT needs to support user assembler name. * config/rs6000/rs6000.c (rs6000_xcoff_asm_output_aligned_decl_common): Use assemble_name to output BSS section name. --- diff --git a/gcc/config/rs6000/rs6000.c b/gcc/config/rs6000/rs6000.c index 835af7708f91..b01bb5c8191c 100644 --- a/gcc/config/rs6000/rs6000.c +++ b/gcc/config/rs6000/rs6000.c @@ -21654,10 +21654,16 @@ rs6000_xcoff_asm_output_aligned_decl_common (FILE *stream, /* Globalize TLS BSS. */ if (TREE_PUBLIC (decl) && DECL_THREAD_LOCAL_P (decl)) - fprintf (stream, "\t.globl %s\n", name); + { + fputs (GLOBAL_ASM_OP, stream); + assemble_name (stream, name); + fputc ('\n', stream); + } /* Switch to section and skip space. */ - fprintf (stream, "\t.csect %s,%u\n", name, align2); + fputs ("\t.csect ", stream); + assemble_name (stream, name); + fprintf (stream, ",%u\n", align2); ASM_DECLARE_OBJECT_NAME (stream, name, decl); ASM_OUTPUT_SKIP (stream, size ? size : 1); return;