alpha.c (TARGET_ASM_GLOBALIZE_LABEL): Define for unicosmk.
* alpha.c (TARGET_ASM_GLOBALIZE_LABEL): Define for unicosmk. * alpha/elf.h (ASM_OUTPUT_EXTERNAL_LIBCALL, ASM_OUTPUT_ALIGNED_BSS): Use target hook. * alpha/osf.h (ASM_OUTPUT_WEAK_ALIAS): Likewise. * alpha/unicosmk.h (ASM_GLOBALIZE_LABEL): Delete. * arm/aof.h (ASM_GLOBALIZE_LABEL): Likewise. (GLOBAL_ASM_OP): Define. * arm.c (aof_globalize_label): New function. (TARGET_ASM_GLOBALIZE_LABEL): Define for AOF. * arm/unknown-elf.h (ASM_OUTPUT_ALIGNED_BSS): Use target hook. * c4x.c (c4x_globalize_label): New function. (TARGET_ASM_GLOBALIZE_LABEL): Define for c4x. * c4x.h (ASM_GLOBALIZE_LABEL): Delete. (GLOBAL_ASM_OP): Define. * cris/aout.h (ASM_OUTPUT_EXTERNAL_LIBCALL): Use target hook. * darwin-protos.h (darwin_globalize_label): Declare. * darwin.c (darwin_globalize_label): New function. * darwin.h (ASM_DECLARE_CLASS_REFERENCE): Use target hook. (ASM_GLOBALIZE_LABEL): Delete. (GLOBAL_ASM_OP, TARGET_ASM_GLOBALIZE_LABEL): Define. * dsp16xx.c (asm_output_common): Use target hook. * elfos.h (ASM_OUTPUT_EXTERNAL_LIBCALL): Likewise. * frv.h (ASM_GLOBALIZE_LABEL): Delete. (GLOBAL_ASM_OP): Define. * i370.c (i370_globalize_label): New function. (TARGET_ASM_GLOBALIZE_LABEL): Define for i370. * i370.h (ASM_GLOBALIZE_LABEL): Delete. * i386.c (ix86_asm_file_end): Use target hook. * i386/sco5.h (ASM_GLOBALIZE_LABEL): Don't undef. (ASM_OUTPUT_EXTERNAL_LIBCALL): Use target hook. * ia64.c (ia64_asm_output_external): Likewise. * ia64/sysv4.h: Update comment. * m32r.h (ASM_OUTPUT_ALIGNED_BSS): Use target hook. * mips/elf.h (ASM_OUTPUT_ALIGNED_BSS): Likewise. * mips/iris5.h (ASM_OUTPUT_WEAK_ALIAS): Use target hook. * mips/linux.h (ASM_OUTPUT_ALIGNED_BSS): Likewise. * mips.h (ASM_OUTPUT_ALIGNED_DECL_COMMON): Use target hook. * mmix-protos.h (mmix_asm_globalize_label): Delete. * mmix.c (mmix_asm_globalize_label): Likewise. * mmix.h (ASM_GLOBALIZE_LABEL): Likewise. (GLOBAL_ASM_OP): Define. * ns32k.c (ns32k_globalize_label): New function. * ns32k.h (TARGET_ASM_GLOBALIZE_LABEL): Define for ns32k. (ASM_GLOBALIZE_LABEL): Delete. * pa/pa-linux.h (ASM_GLOBALIZE_LABEL): Don't undef. (TARGET_ASM_GLOBALIZE_LABEL): Undefine. * pa.c (pa_globalize_label): New function. * pa.h (ASM_GLOBALIZE_LABEL): Delete. (TARGET_ASM_GLOBALIZE_LABEL): Define for pa. * rs6000/darwin.h (ASM_GLOBALIZE_LABEL): Delete. (GLOBAL_ASM_OP): Define. (TARGET_ASM_GLOBALIZE_LABEL): Undef. * rs6000/sysv4.h (ASM_OUTPUT_ALIGNED_BSS): Use target hook. * rs6000/xcoff.h (ASM_GLOBALIZE_LABEL): Delete. (GLOBAL_ASM_OP): Define. * v850.c (v850_output_aligned_bss): Use target hook. * vax.c (vms_globalize_label): New function. (TARGET_ASM_GLOBALIZE_LABEL): Define for vms. * vax/vms.h (ASM_GLOBALIZE_LABEL): Delete. (GLOBAL_ASM_OP): Define. * defaults.h (ASM_GLOBALIZE_LABEL): Delete. * doc/tm.texi: Update docs. * dwarf2out.c (default_eh_frame_section, output_die_symbol): Use target hook. * final.c (output_alternate_entry_point): Likewise. * hooks.c (hook_FILEptr_constcharptr_void): New function. * hooks.h (hook_FILEptr_constcharptr_void): Declare. * output.h (assemble_global): Delete. (default_globalize_label): Declare. * system.h (ASM_GLOBALIZE_LABEL): Poison. * target-def.h (TARGET_ASM_GLOBALIZE_LABEL): Define. (TARGET_ASM_OUT): Add TARGET_ASM_GLOBALIZE_LABEL. * target.h (gcc_target): Add globalize_label member. * varasm.c (asm_output_bss, asm_output_aligned_bss, globalize_decl): Use target hook. (assemble_global): Delete. (default_globalize_label): New function. From-SVN: r56478
This commit is contained in:
parent
f8f28a755c
commit
5eb99654a2
|
@ -1,3 +1,83 @@
|
|||
2002-08-20 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
|
||||
|
||||
* alpha.c (TARGET_ASM_GLOBALIZE_LABEL): Define for unicosmk.
|
||||
* alpha/elf.h (ASM_OUTPUT_EXTERNAL_LIBCALL,
|
||||
ASM_OUTPUT_ALIGNED_BSS): Use target hook.
|
||||
* alpha/osf.h (ASM_OUTPUT_WEAK_ALIAS): Likewise.
|
||||
* alpha/unicosmk.h (ASM_GLOBALIZE_LABEL): Delete.
|
||||
* arm/aof.h (ASM_GLOBALIZE_LABEL): Likewise.
|
||||
(GLOBAL_ASM_OP): Define.
|
||||
* arm.c (aof_globalize_label): New function.
|
||||
(TARGET_ASM_GLOBALIZE_LABEL): Define for AOF.
|
||||
* arm/unknown-elf.h (ASM_OUTPUT_ALIGNED_BSS): Use target hook.
|
||||
* c4x.c (c4x_globalize_label): New function.
|
||||
(TARGET_ASM_GLOBALIZE_LABEL): Define for c4x.
|
||||
* c4x.h (ASM_GLOBALIZE_LABEL): Delete.
|
||||
(GLOBAL_ASM_OP): Define.
|
||||
* cris/aout.h (ASM_OUTPUT_EXTERNAL_LIBCALL): Use target hook.
|
||||
* darwin-protos.h (darwin_globalize_label): Declare.
|
||||
* darwin.c (darwin_globalize_label): New function.
|
||||
* darwin.h (ASM_DECLARE_CLASS_REFERENCE): Use target hook.
|
||||
(ASM_GLOBALIZE_LABEL): Delete.
|
||||
(GLOBAL_ASM_OP, TARGET_ASM_GLOBALIZE_LABEL): Define.
|
||||
* dsp16xx.c (asm_output_common): Use target hook.
|
||||
* elfos.h (ASM_OUTPUT_EXTERNAL_LIBCALL): Likewise.
|
||||
* frv.h (ASM_GLOBALIZE_LABEL): Delete.
|
||||
(GLOBAL_ASM_OP): Define.
|
||||
* i370.c (i370_globalize_label): New function.
|
||||
(TARGET_ASM_GLOBALIZE_LABEL): Define for i370.
|
||||
* i370.h (ASM_GLOBALIZE_LABEL): Delete.
|
||||
* i386.c (ix86_asm_file_end): Use target hook.
|
||||
* i386/sco5.h (ASM_GLOBALIZE_LABEL): Don't undef.
|
||||
(ASM_OUTPUT_EXTERNAL_LIBCALL): Use target hook.
|
||||
* ia64.c (ia64_asm_output_external): Likewise.
|
||||
* ia64/sysv4.h: Update comment.
|
||||
* m32r.h (ASM_OUTPUT_ALIGNED_BSS): Use target hook.
|
||||
* mips/elf.h (ASM_OUTPUT_ALIGNED_BSS): Likewise.
|
||||
* mips/iris5.h (ASM_OUTPUT_WEAK_ALIAS): Use target hook.
|
||||
* mips/linux.h (ASM_OUTPUT_ALIGNED_BSS): Likewise.
|
||||
* mips.h (ASM_OUTPUT_ALIGNED_DECL_COMMON): Use target hook.
|
||||
* mmix-protos.h (mmix_asm_globalize_label): Delete.
|
||||
* mmix.c (mmix_asm_globalize_label): Likewise.
|
||||
* mmix.h (ASM_GLOBALIZE_LABEL): Likewise.
|
||||
(GLOBAL_ASM_OP): Define.
|
||||
* ns32k.c (ns32k_globalize_label): New function.
|
||||
* ns32k.h (TARGET_ASM_GLOBALIZE_LABEL): Define for ns32k.
|
||||
(ASM_GLOBALIZE_LABEL): Delete.
|
||||
* pa/pa-linux.h (ASM_GLOBALIZE_LABEL): Don't undef.
|
||||
(TARGET_ASM_GLOBALIZE_LABEL): Undefine.
|
||||
* pa.c (pa_globalize_label): New function.
|
||||
* pa.h (ASM_GLOBALIZE_LABEL): Delete.
|
||||
(TARGET_ASM_GLOBALIZE_LABEL): Define for pa.
|
||||
* rs6000/darwin.h (ASM_GLOBALIZE_LABEL): Delete.
|
||||
(GLOBAL_ASM_OP): Define.
|
||||
(TARGET_ASM_GLOBALIZE_LABEL): Undef.
|
||||
* rs6000/sysv4.h (ASM_OUTPUT_ALIGNED_BSS): Use target hook.
|
||||
* rs6000/xcoff.h (ASM_GLOBALIZE_LABEL): Delete.
|
||||
(GLOBAL_ASM_OP): Define.
|
||||
* v850.c (v850_output_aligned_bss): Use target hook.
|
||||
* vax.c (vms_globalize_label): New function.
|
||||
(TARGET_ASM_GLOBALIZE_LABEL): Define for vms.
|
||||
* vax/vms.h (ASM_GLOBALIZE_LABEL): Delete.
|
||||
(GLOBAL_ASM_OP): Define.
|
||||
* defaults.h (ASM_GLOBALIZE_LABEL): Delete.
|
||||
* doc/tm.texi: Update docs.
|
||||
* dwarf2out.c (default_eh_frame_section, output_die_symbol): Use
|
||||
target hook.
|
||||
* final.c (output_alternate_entry_point): Likewise.
|
||||
* hooks.c (hook_FILEptr_constcharptr_void): New function.
|
||||
* hooks.h (hook_FILEptr_constcharptr_void): Declare.
|
||||
* output.h (assemble_global): Delete.
|
||||
(default_globalize_label): Declare.
|
||||
* system.h (ASM_GLOBALIZE_LABEL): Poison.
|
||||
* target-def.h (TARGET_ASM_GLOBALIZE_LABEL): Define.
|
||||
(TARGET_ASM_OUT): Add TARGET_ASM_GLOBALIZE_LABEL.
|
||||
* target.h (gcc_target): Add globalize_label member.
|
||||
* varasm.c (asm_output_bss, asm_output_aligned_bss,
|
||||
globalize_decl): Use target hook.
|
||||
(assemble_global): Delete.
|
||||
(default_globalize_label): New function.
|
||||
|
||||
2002-08-20 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
|
||||
|
||||
* dsp16xx.h (dsp16xx_umulhi3_libcall): Delete.
|
||||
|
|
|
@ -245,6 +245,8 @@ static void unicosmk_unique_section PARAMS ((tree, int));
|
|||
# define TARGET_SECTION_TYPE_FLAGS unicosmk_section_type_flags
|
||||
# undef TARGET_ASM_UNIQUE_SECTION
|
||||
# define TARGET_ASM_UNIQUE_SECTION unicosmk_unique_section
|
||||
# undef TARGET_ASM_GLOBALIZE_LABEL
|
||||
# define TARGET_ASM_GLOBALIZE_LABEL hook_FILEptr_constcharptr_void
|
||||
#endif
|
||||
|
||||
#undef TARGET_ASM_ALIGNED_HI_OP
|
||||
|
|
|
@ -112,7 +112,7 @@ do { \
|
|||
|
||||
#undef ASM_OUTPUT_EXTERNAL_LIBCALL
|
||||
#define ASM_OUTPUT_EXTERNAL_LIBCALL(FILE, FUN) \
|
||||
ASM_GLOBALIZE_LABEL (FILE, XSTR (FUN, 0))
|
||||
(*targetm.asm_out.globalize_label) (FILE, XSTR (FUN, 0))
|
||||
|
||||
/* This says how to output assembler code to declare an
|
||||
uninitialized external linkage data object. Under SVR4,
|
||||
|
@ -156,7 +156,7 @@ do { \
|
|||
#undef ASM_OUTPUT_ALIGNED_BSS
|
||||
#define ASM_OUTPUT_ALIGNED_BSS(FILE, DECL, NAME, SIZE, ALIGN) \
|
||||
do { \
|
||||
ASM_GLOBALIZE_LABEL (FILE, NAME); \
|
||||
(*targetm.asm_out.globalize_label) (FILE, NAME); \
|
||||
ASM_OUTPUT_ALIGNED_LOCAL (FILE, NAME, SIZE, ALIGN); \
|
||||
} while (0)
|
||||
|
||||
|
|
|
@ -198,7 +198,7 @@ __enable_execute_stack (addr) \
|
|||
#define ASM_OUTPUT_WEAK_ALIAS(FILE, NAME, VALUE) \
|
||||
do \
|
||||
{ \
|
||||
ASM_GLOBALIZE_LABEL (FILE, NAME); \
|
||||
(*targetm.asm_out.globalize_label) (FILE, NAME); \
|
||||
fputs ("\t.weakext\t", FILE); \
|
||||
assemble_name (FILE, NAME); \
|
||||
if (VALUE) \
|
||||
|
|
|
@ -349,12 +349,6 @@ ssib_section () \
|
|||
|
||||
#undef ASM_OUTPUT_SOURCE_FILENAME
|
||||
|
||||
/* There is no directive for declaring a label as global. Instead, an
|
||||
additional colon must be appended when the label is defined. */
|
||||
|
||||
#undef ASM_GLOBALIZE_LABEL
|
||||
#define ASM_GLOBALIZE_LABEL(FILE,NAME)
|
||||
|
||||
/* This is how to output a label for a jump table. Arguments are the same as
|
||||
for ASM_OUTPUT_INTERNAL_LABEL, except the insn for the jump table is
|
||||
passed. */
|
||||
|
|
|
@ -220,14 +220,8 @@ do \
|
|||
|
||||
extern int arm_main_function;
|
||||
|
||||
#define ASM_GLOBALIZE_LABEL(STREAM,NAME) \
|
||||
do { \
|
||||
fprintf ((STREAM), "\tEXPORT\t"); \
|
||||
assemble_name ((STREAM), (NAME)); \
|
||||
fputc ('\n', (STREAM)); \
|
||||
if ((NAME)[0] == 'm' && ! strcmp ((NAME), "main")) \
|
||||
arm_main_function = 1; \
|
||||
} while (0)
|
||||
/* Globalizing directive for a label. */
|
||||
#define GLOBAL_ASM_OP "\tEXPORT\t"
|
||||
|
||||
#define ASM_OUTPUT_LABEL(STREAM,NAME) \
|
||||
do { \
|
||||
|
|
|
@ -123,6 +123,9 @@ static void arm_elf_asm_named_section PARAMS ((const char *, unsigned int));
|
|||
#ifndef ARM_PE
|
||||
static void arm_encode_section_info PARAMS ((tree, int));
|
||||
#endif
|
||||
#ifdef AOF_ASSEMBLER
|
||||
static void aof_globalize_label PARAMS ((FILE *, const char *));
|
||||
#endif
|
||||
|
||||
#undef Hint
|
||||
#undef Mmode
|
||||
|
@ -145,6 +148,8 @@ static void arm_encode_section_info PARAMS ((tree, int));
|
|||
#define TARGET_ASM_ALIGNED_HI_OP "\tDCW\t"
|
||||
#undef TARGET_ASM_ALIGNED_SI_OP
|
||||
#define TARGET_ASM_ALIGNED_SI_OP "\tDCD\t"
|
||||
#undef TARGET_ASM_GLOBALIZE_LABEL
|
||||
#define TARGET_ASM_GLOBALIZE_LABEL aof_globalize_label
|
||||
#else
|
||||
#undef TARGET_ASM_ALIGNED_SI_OP
|
||||
#define TARGET_ASM_ALIGNED_SI_OP NULL
|
||||
|
@ -10950,6 +10955,16 @@ aof_dump_imports (f)
|
|||
imports_list = imports_list->next;
|
||||
}
|
||||
}
|
||||
|
||||
static void
|
||||
aof_globalize_label (stream, name)
|
||||
FILE *stream;
|
||||
const char *name;
|
||||
{
|
||||
default_globalize_label (stream, name);
|
||||
if (! strcmp (name, "main"))
|
||||
arm_main_function = 1;
|
||||
}
|
||||
#endif /* AOF_ASSEMBLER */
|
||||
|
||||
#ifdef OBJECT_FORMAT_ELF
|
||||
|
|
|
@ -61,7 +61,7 @@ Boston, MA 02111-1307, USA. */
|
|||
else \
|
||||
bss_section (); \
|
||||
\
|
||||
ASM_GLOBALIZE_LABEL (FILE, NAME); \
|
||||
(*targetm.asm_out.globalize_label) (FILE, NAME); \
|
||||
\
|
||||
ASM_OUTPUT_ALIGN (FILE, floor_log2 (ALIGN / BITS_PER_UNIT)); \
|
||||
\
|
||||
|
|
|
@ -193,6 +193,7 @@ static void c4x_insert_attributes PARAMS ((tree, tree *));
|
|||
static void c4x_asm_named_section PARAMS ((const char *, unsigned int));
|
||||
static int c4x_adjust_cost PARAMS ((rtx, rtx, rtx, int));
|
||||
static void c4x_encode_section_info PARAMS ((tree, int));
|
||||
static void c4x_globalize_label PARAMS ((FILE *, const char *));
|
||||
|
||||
/* Initialize the GCC target structure. */
|
||||
#undef TARGET_ASM_BYTE_OP
|
||||
|
@ -220,6 +221,9 @@ static void c4x_encode_section_info PARAMS ((tree, int));
|
|||
#undef TARGET_ENCODE_SECTION_INFO
|
||||
#define TARGET_ENCODE_SECTION_INFO c4x_encode_section_info
|
||||
|
||||
#undef TARGET_ASM_GLOBALIZE_LABEL
|
||||
#define TARGET_ASM_GLOBALIZE_LABEL c4x_globalize_label
|
||||
|
||||
struct gcc_target targetm = TARGET_INITIALIZER;
|
||||
|
||||
/* Override command line options.
|
||||
|
@ -5045,3 +5049,11 @@ c4x_asm_named_section (name, flags)
|
|||
fprintf (asm_out_file, "\t.sect\t\"%s\"\n", name);
|
||||
}
|
||||
|
||||
static void
|
||||
c4x_globalize_label (stream, name)
|
||||
FILE *stream;
|
||||
const char *name;
|
||||
{
|
||||
default_globalize_label (stream, name);
|
||||
c4x_global_label (name);
|
||||
}
|
||||
|
|
|
@ -1704,13 +1704,8 @@ fini_section () \
|
|||
|
||||
#define NO_DOT_IN_LABEL /* Only required for TI format. */
|
||||
|
||||
#define ASM_GLOBALIZE_LABEL(FILE, NAME) \
|
||||
do { \
|
||||
fprintf (FILE, "\t.global\t"); \
|
||||
assemble_name (FILE, NAME); \
|
||||
fputs ("\n", FILE); \
|
||||
c4x_global_label (NAME); \
|
||||
} while (0);
|
||||
/* Globalizing directive for a label. */
|
||||
#define GLOBAL_ASM_OP "\t.global\t"
|
||||
|
||||
#define ASM_OUTPUT_EXTERNAL(FILE, DECL, NAME) \
|
||||
c4x_external_ref (NAME)
|
||||
|
|
|
@ -277,7 +277,7 @@ Boston, MA 02111-1307, USA. */
|
|||
#define SET_ASM_OP "\t.set\t"
|
||||
|
||||
#define ASM_OUTPUT_EXTERNAL_LIBCALL(FILE, FUN) \
|
||||
ASM_GLOBALIZE_LABEL (FILE, XSTR (FUN, 0))
|
||||
(*targetm.asm_out.globalize_label) (FILE, XSTR (FUN, 0))
|
||||
|
||||
#define ASM_WEAKEN_LABEL(FILE, NAME) \
|
||||
do \
|
||||
|
|
|
@ -114,3 +114,4 @@ extern void machopic_symbol_stub_section PARAMS ((void));
|
|||
extern void machopic_picsymbol_stub_section PARAMS ((void));
|
||||
extern void darwin_exception_section PARAMS ((void));
|
||||
extern void darwin_eh_frame_section PARAMS ((void));
|
||||
extern void darwin_globalize_label PARAMS ((FILE *, const char *));
|
||||
|
|
|
@ -1285,5 +1285,14 @@ machopic_asm_out_destructor (symbol, priority)
|
|||
fprintf (asm_out_file, ".reference .destructors_used\n");
|
||||
}
|
||||
|
||||
void
|
||||
darwin_globalize_label (stream, name)
|
||||
FILE *stream;
|
||||
const char *name;
|
||||
{
|
||||
if (!!strncmp (name, "_OBJC_", 6))
|
||||
default_globalize_label (stream, name);
|
||||
}
|
||||
|
||||
#include "gt-darwin.h"
|
||||
|
||||
|
|
|
@ -504,15 +504,13 @@ objc_section_init () \
|
|||
fprintf (FILE, "\t"); \
|
||||
assemble_name (FILE, NAME); \
|
||||
fprintf (FILE, "=0\n"); \
|
||||
assemble_global (NAME); \
|
||||
(*targetm.asm_out.globalize_label) (FILE, NAME); \
|
||||
} \
|
||||
} while (0)
|
||||
|
||||
#undef ASM_GLOBALIZE_LABEL
|
||||
#define ASM_GLOBALIZE_LABEL(FILE,NAME) \
|
||||
do { const char *const _x = (NAME); if (!!strncmp (_x, "_OBJC_", 6)) { \
|
||||
(fputs (".globl ", FILE), assemble_name (FILE, _x), fputs ("\n", FILE)); \
|
||||
}} while (0)
|
||||
/* Globalizing directive for a label. */
|
||||
#define GLOBAL_ASM_OP ".globl "
|
||||
#define TARGET_ASM_GLOBALIZE_LABEL darwin_globalize_label
|
||||
|
||||
#undef ASM_GENERATE_INTERNAL_LABEL
|
||||
#define ASM_GENERATE_INTERNAL_LABEL(LABEL,PREFIX,NUM) \
|
||||
|
|
|
@ -2198,7 +2198,7 @@ asm_output_common(file, name, size, rounded)
|
|||
int rounded;
|
||||
{
|
||||
bss_section ();
|
||||
ASM_GLOBALIZE_LABEL (file, name);
|
||||
(*targetm.asm_out.globalize_label) (file, name);
|
||||
assemble_name (file, name);
|
||||
fputs (":", file);
|
||||
if (rounded > 1)
|
||||
|
|
|
@ -172,7 +172,7 @@ Boston, MA 02111-1307, USA. */
|
|||
in each assembly file where they are referenced. */
|
||||
|
||||
#define ASM_OUTPUT_EXTERNAL_LIBCALL(FILE, FUN) \
|
||||
ASM_GLOBALIZE_LABEL (FILE, XSTR (FUN, 0))
|
||||
(*targetm.asm_out.globalize_label) (FILE, XSTR (FUN, 0))
|
||||
|
||||
/* This says how to output assembler code to declare an
|
||||
uninitialized external linkage data object. Under SVR4,
|
||||
|
|
|
@ -2997,17 +2997,8 @@ do { \
|
|||
fputs (":\n", STREAM); \
|
||||
} while (0)
|
||||
|
||||
/* A C statement (sans semicolon) to output to the stdio stream STREAM some
|
||||
commands that will make the label NAME global; that is, available for
|
||||
reference from other files. Use the expression `assemble_name (STREAM,
|
||||
NAME)' to output the name itself; before and after that, output the
|
||||
additional assembler syntax for making that name global, and a newline. */
|
||||
#define ASM_GLOBALIZE_LABEL(STREAM, NAME) \
|
||||
do { \
|
||||
fputs ("\t.globl ", STREAM); \
|
||||
assemble_name (STREAM, NAME); \
|
||||
fputs ("\n", STREAM); \
|
||||
} while (0)
|
||||
/* Globalizing directive for a label. */
|
||||
#define GLOBAL_ASM_OP "\t.globl "
|
||||
|
||||
/* A C statement (sans semicolon) to output to the stdio stream STREAM a
|
||||
reference in assembler syntax to a label named NAME. This should add `_' to
|
||||
|
|
|
@ -101,6 +101,7 @@ static label_node_t * mvs_get_label PARAMS ((int));
|
|||
static void i370_label_scan PARAMS ((void));
|
||||
#ifdef TARGET_HLASM
|
||||
static bool i370_hlasm_assemble_integer PARAMS ((rtx, unsigned int, int));
|
||||
static void i370_globalize_label PARAMS ((FILE *, const char *));
|
||||
#endif
|
||||
static void i370_output_function_prologue PARAMS ((FILE *, HOST_WIDE_INT));
|
||||
static void i370_output_function_epilogue PARAMS ((FILE *, HOST_WIDE_INT));
|
||||
|
@ -301,6 +302,8 @@ static const unsigned char ebcasc[256] =
|
|||
#define TARGET_ASM_ALIGNED_SI_OP NULL
|
||||
#undef TARGET_ASM_INTEGER
|
||||
#define TARGET_ASM_INTEGER i370_hlasm_assemble_integer
|
||||
#undef TARGET_ASM_GLOBALIZE_LABEL
|
||||
#define TARGET_ASM_GLOBALIZE_LABEL i370_globalize_label
|
||||
#endif
|
||||
|
||||
#undef TARGET_ASM_FUNCTION_PROLOGUE
|
||||
|
@ -1416,6 +1419,19 @@ i370_output_function_prologue (f, l)
|
|||
/* find all labels in this routine */
|
||||
i370_label_scan ();
|
||||
}
|
||||
|
||||
static void
|
||||
i370_globalize_label (stream, name)
|
||||
FILE *stream;
|
||||
const char *name;
|
||||
{
|
||||
char temp[MAX_MVS_LABEL_SIZE + 1];
|
||||
if (mvs_check_alias (name, temp) == 2)
|
||||
fprintf (stream, "%s\tALIAS\tC'%s'\n", temp, name);
|
||||
fputs ("\tENTRY\t", stream);
|
||||
assemble_name (stream, name);
|
||||
putc ('\n', stream);
|
||||
}
|
||||
#endif /* TARGET_HLASM */
|
||||
|
||||
|
||||
|
|
|
@ -1073,18 +1073,6 @@ enum reg_class
|
|||
} \
|
||||
}
|
||||
|
||||
#define ASM_GLOBALIZE_LABEL(FILE, NAME) \
|
||||
{ \
|
||||
char temp[MAX_MVS_LABEL_SIZE + 1]; \
|
||||
if (mvs_check_alias (NAME, temp) == 2) \
|
||||
{ \
|
||||
fprintf (FILE, "%s\tALIAS\tC'%s'\n", temp, NAME); \
|
||||
} \
|
||||
fputs ("\tENTRY\t", FILE); \
|
||||
assemble_name (FILE, NAME); \
|
||||
fputs ("\n", FILE); \
|
||||
}
|
||||
|
||||
/* MVS externals are limited to 8 characters, upper case only.
|
||||
The '_' is mapped to '@', except for MVS functions, then '#'. */
|
||||
|
||||
|
|
|
@ -3931,7 +3931,7 @@ ix86_asm_file_end (file)
|
|||
(*targetm.asm_out.unique_section) (decl, 0);
|
||||
named_section (decl, NULL, 0);
|
||||
|
||||
ASM_GLOBALIZE_LABEL (file, name);
|
||||
(*targetm.asm_out.globalize_label) (file, name);
|
||||
fputs ("\t.hidden\t", file);
|
||||
assemble_name (file, name);
|
||||
fputc ('\n', file);
|
||||
|
|
|
@ -350,11 +350,9 @@ do { \
|
|||
#define ASM_OUTPUT_IDENT(FILE, NAME) \
|
||||
fprintf (FILE, "%s\"%s\"\n", IDENT_ASM_OP, NAME);
|
||||
|
||||
#undef ASM_GLOBALIZE_LABEL
|
||||
|
||||
#undef ASM_OUTPUT_EXTERNAL_LIBCALL
|
||||
#define ASM_OUTPUT_EXTERNAL_LIBCALL(FILE, FUN) \
|
||||
if (TARGET_ELF) ASM_GLOBALIZE_LABEL (FILE, XSTR (FUN, 0))
|
||||
if (TARGET_ELF) (*targetm.asm_out.globalize_label) (FILE, XSTR (FUN, 0))
|
||||
|
||||
#undef ASM_OUTPUT_INTERNAL_LABEL
|
||||
#define ASM_OUTPUT_INTERNAL_LABEL(FILE,PREFIX,NUM) \
|
||||
|
|
|
@ -4060,7 +4060,7 @@ ia64_asm_output_external (file, decl, name)
|
|||
save_referenced = TREE_SYMBOL_REFERENCED (DECL_ASSEMBLER_NAME (decl));
|
||||
if (TREE_CODE (decl) == FUNCTION_DECL)
|
||||
ASM_OUTPUT_TYPE_DIRECTIVE (file, name, "function");
|
||||
ASM_GLOBALIZE_LABEL (file, name);
|
||||
(*targetm.asm_out.globalize_label) (file, name);
|
||||
TREE_SYMBOL_REFERENCED (DECL_ASSEMBLER_NAME (decl)) = save_referenced;
|
||||
}
|
||||
|
||||
|
|
|
@ -33,8 +33,8 @@
|
|||
the Intel simulator. So we must explicitly put variables in .bss
|
||||
instead. This matters only if we care about the Intel assembler. */
|
||||
|
||||
/* This is asm_output_aligned_bss from varasm.c without the ASM_GLOBALIZE_LABEL
|
||||
call at the beginning. */
|
||||
/* This is asm_output_aligned_bss from varasm.c without the
|
||||
(*targetm.asm_out.globalize_label) call at the beginning. */
|
||||
|
||||
/* This is for final.c, because it is used by ASM_DECLARE_OBJECT_NAME. */
|
||||
extern int size_directive_output;
|
||||
|
|
|
@ -1852,7 +1852,7 @@ extern char m32r_punct_chars[256];
|
|||
#define ASM_OUTPUT_ALIGNED_BSS(FILE, DECL, NAME, SIZE, ALIGN) \
|
||||
do \
|
||||
{ \
|
||||
ASM_GLOBALIZE_LABEL (FILE, NAME); \
|
||||
(*targetm.asm_out.globalize_label) (FILE, NAME); \
|
||||
ASM_OUTPUT_ALIGNED_COMMON (FILE, NAME, SIZE, ALIGN); \
|
||||
} \
|
||||
while (0)
|
||||
|
|
|
@ -106,7 +106,7 @@ do { \
|
|||
#ifndef ASM_OUTPUT_ALIGNED_BSS
|
||||
#define ASM_OUTPUT_ALIGNED_BSS(FILE, DECL, NAME, SIZE, ALIGN) \
|
||||
do { \
|
||||
ASM_GLOBALIZE_LABEL (FILE, NAME); \
|
||||
(*targetm.asm_out.globalize_label) (FILE, NAME); \
|
||||
if (SIZE > 0 && SIZE <= mips_section_threshold) \
|
||||
sbss_section (); \
|
||||
else \
|
||||
|
|
|
@ -190,7 +190,7 @@ do { \
|
|||
#define ASM_OUTPUT_WEAK_ALIAS(FILE, NAME, VALUE) \
|
||||
do \
|
||||
{ \
|
||||
ASM_GLOBALIZE_LABEL (FILE, NAME); \
|
||||
(*targetm.asm_out.globalize_label) (FILE, NAME); \
|
||||
fputs ("\t.weakext\t", FILE); \
|
||||
assemble_name (FILE, NAME); \
|
||||
if (VALUE) \
|
||||
|
|
|
@ -45,7 +45,7 @@ Boston, MA 02111-1307, USA. */
|
|||
`varasm.c' when defining this macro. */
|
||||
#define ASM_OUTPUT_ALIGNED_BSS(FILE, DECL, NAME, SIZE, ALIGN) \
|
||||
do { \
|
||||
ASM_GLOBALIZE_LABEL (FILE, NAME); \
|
||||
(*targetm.asm_out.globalize_label) (FILE, NAME); \
|
||||
if (SIZE > 0 && SIZE <= mips_section_threshold) \
|
||||
sbss_section (); \
|
||||
else \
|
||||
|
|
|
@ -4335,7 +4335,7 @@ while (0)
|
|||
|| DECL_INITIAL (DECL) == error_mark_node)) \
|
||||
{ \
|
||||
if (TREE_PUBLIC (DECL) && DECL_NAME (DECL)) \
|
||||
ASM_GLOBALIZE_LABEL (STREAM, NAME); \
|
||||
(*targetm.asm_out.globalize_label) (STREAM, NAME); \
|
||||
\
|
||||
readonly_data_section (); \
|
||||
ASM_OUTPUT_ALIGN (STREAM, floor_log2 (ALIGN / BITS_PER_UNIT)); \
|
||||
|
|
|
@ -40,7 +40,6 @@ extern void mmix_output_quoted_string PARAMS ((FILE *, const char *, int));
|
|||
extern void mmix_asm_output_source_line PARAMS ((FILE *, int));
|
||||
extern void mmix_asm_output_ascii PARAMS ((FILE *, const char *, int));
|
||||
extern void mmix_asm_output_label PARAMS ((FILE *, const char *));
|
||||
extern void mmix_asm_globalize_label PARAMS ((FILE *, const char *));
|
||||
extern void mmix_asm_weaken_label PARAMS ((FILE *, const char *));
|
||||
extern void mmix_asm_output_labelref PARAMS ((FILE *, const char *));
|
||||
extern void mmix_asm_output_internal_label
|
||||
|
|
|
@ -1520,18 +1520,6 @@ mmix_asm_declare_register_global (stream, decl, regno, name)
|
|||
here. */
|
||||
}
|
||||
|
||||
/* ASM_GLOBALIZE_LABEL. */
|
||||
|
||||
void
|
||||
mmix_asm_globalize_label (stream, name)
|
||||
FILE * stream ATTRIBUTE_UNUSED;
|
||||
const char * name ATTRIBUTE_UNUSED;
|
||||
{
|
||||
asm_fprintf (stream, "\t.global ");
|
||||
assemble_name (stream, name);
|
||||
putc ('\n', stream);
|
||||
}
|
||||
|
||||
/* ASM_WEAKEN_LABEL. */
|
||||
|
||||
void
|
||||
|
|
|
@ -980,8 +980,7 @@ typedef struct { int regs; int lib; } CUMULATIVE_ARGS;
|
|||
#define ASM_DECLARE_REGISTER_GLOBAL(STREAM, DECL, REGNO, NAME) \
|
||||
mmix_asm_declare_register_global (STREAM, DECL, REGNO, NAME)
|
||||
|
||||
#define ASM_GLOBALIZE_LABEL(STREAM, NAME) \
|
||||
mmix_asm_globalize_label (STREAM, NAME)
|
||||
#define GLOBAL_ASM_OP "\t.global "
|
||||
|
||||
#define ASM_WEAKEN_LABEL(STREAM, NAME) \
|
||||
mmix_asm_weaken_label (STREAM, NAME)
|
||||
|
|
|
@ -70,6 +70,9 @@ const struct attribute_spec ns32k_attribute_table[];
|
|||
static void ns32k_output_function_prologue PARAMS ((FILE *, HOST_WIDE_INT));
|
||||
static void ns32k_output_function_epilogue PARAMS ((FILE *, HOST_WIDE_INT));
|
||||
static void ns32k_encode_section_info PARAMS ((tree, int));
|
||||
#ifdef COLLECT
|
||||
static void ns32k_globalize_label PARAMS ((FILE *, const char *));
|
||||
#endif
|
||||
|
||||
/* Initialize the GCC target structure. */
|
||||
#undef TARGET_ATTRIBUTE_TABLE
|
||||
|
@ -1573,3 +1576,13 @@ ns32k_encode_section_info (decl, first)
|
|||
|| ! TREE_PUBLIC (decl));
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef COLLECT
|
||||
static void
|
||||
ns32k_globalize_label (stream, name)
|
||||
FILE *stream;
|
||||
const char *name;
|
||||
{
|
||||
fprintf (stream, "\t.globl\t%s\n", name);
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -1319,12 +1319,11 @@ __transfer_from_trampoline () \
|
|||
/* This is how to output a command to make the user-level label named NAME
|
||||
defined for reference from other files. */
|
||||
|
||||
#ifndef COLLECT
|
||||
#ifdef COLLECT
|
||||
#define TARGET_ASM_GLOBALIZE_LABEL ns32k_globalize_label
|
||||
#else
|
||||
/* Globalizing directive for a label. */
|
||||
#define GLOBAL_ASM_OP ".globl "
|
||||
#else
|
||||
#define ASM_GLOBALIZE_LABEL(STREAM,NAME) \
|
||||
fprintf ((STREAM), "\t.globl\t%s\n", (NAME));
|
||||
#endif
|
||||
|
||||
/* This is how to output an internal numbered label where
|
||||
|
|
|
@ -169,7 +169,7 @@ Boston, MA 02111-1307, USA. */
|
|||
ASM_GENERATE_INTERNAL_LABEL(), so do not define it here. */
|
||||
|
||||
/* Use the default. */
|
||||
#undef ASM_GLOBALIZE_LABEL
|
||||
#undef TARGET_ASM_GLOBALIZE_LABEL
|
||||
/* Globalizing directive for a label. */
|
||||
#define GLOBAL_ASM_OP ".globl "
|
||||
|
||||
|
|
|
@ -116,6 +116,7 @@ static void pa_select_section PARAMS ((tree, int, unsigned HOST_WIDE_INT))
|
|||
ATTRIBUTE_UNUSED;
|
||||
static void pa_encode_section_info PARAMS ((tree, int));
|
||||
static const char *pa_strip_name_encoding PARAMS ((const char *));
|
||||
static void pa_globalize_label PARAMS ((FILE *, const char *));
|
||||
|
||||
/* Save the operands last given to a compare for use when we
|
||||
generate a scc or bcc insn. */
|
||||
|
@ -7701,4 +7702,18 @@ pa_select_section (exp, reloc, align)
|
|||
data_section ();
|
||||
}
|
||||
|
||||
static void
|
||||
pa_globalize_label (stream, name)
|
||||
FILE *stream;
|
||||
const char *name;
|
||||
{
|
||||
/* We only handle DATA objects here, functions are globalized in
|
||||
ASM_DECLARE_FUNCTION_NAME. */
|
||||
if (! FUNCTION_NAME_P (name))
|
||||
{
|
||||
fputs ("\t.EXPORT ", stream);
|
||||
assemble_name (stream, name);
|
||||
fputs (",DATA\n", stream);
|
||||
}
|
||||
}
|
||||
#include "gt-pa.h"
|
||||
|
|
|
@ -1679,17 +1679,7 @@ do { \
|
|||
#define ASM_GENERATE_INTERNAL_LABEL(LABEL,PREFIX,NUM) \
|
||||
sprintf (LABEL, "*%c$%s%04ld", (PREFIX)[0], (PREFIX) + 1, (long)(NUM))
|
||||
|
||||
#define ASM_GLOBALIZE_LABEL(FILE, NAME) \
|
||||
do { \
|
||||
/* We only handle DATA objects here, functions are globalized in \
|
||||
ASM_DECLARE_FUNCTION_NAME. */ \
|
||||
if (! FUNCTION_NAME_P (NAME)) \
|
||||
{ \
|
||||
fputs ("\t.EXPORT ", FILE); \
|
||||
assemble_name (FILE, NAME); \
|
||||
fputs (",DATA\n", FILE); \
|
||||
} \
|
||||
} while (0)
|
||||
#define TARGET_ASM_GLOBALIZE_LABEL pa_globalize_label
|
||||
|
||||
#define ASM_OUTPUT_ASCII(FILE, P, SIZE) \
|
||||
output_ascii ((FILE), (P), (SIZE))
|
||||
|
|
|
@ -103,13 +103,10 @@ Boston, MA 02111-1307, USA. */
|
|||
#define RS6000_OUTPUT_BASENAME(FILE, NAME) \
|
||||
assemble_name (FILE, NAME);
|
||||
|
||||
/* This is how to output a command to make the user-level label named NAME
|
||||
defined for reference from other files. */
|
||||
|
||||
#undef ASM_GLOBALIZE_LABEL
|
||||
#define ASM_GLOBALIZE_LABEL(FILE,NAME) \
|
||||
do { fputs ("\t.globl ", FILE); \
|
||||
RS6000_OUTPUT_BASENAME (FILE, NAME); putc ('\n', FILE);} while (0)
|
||||
/* Globalizing directive for a label. */
|
||||
#undef GLOBAL_ASM_OP
|
||||
#define GLOBAL_ASM_OP "\t.globl "
|
||||
#undef TARGET_ASM_GLOBALIZE_LABEL
|
||||
|
||||
/* This is how to output an internal label prefix. rs6000.c uses this
|
||||
when generating traceback tables. */
|
||||
|
|
|
@ -716,7 +716,7 @@ do { \
|
|||
/* Describe how to emit uninitialized external linkage items. */
|
||||
#define ASM_OUTPUT_ALIGNED_BSS(FILE, DECL, NAME, SIZE, ALIGN) \
|
||||
do { \
|
||||
ASM_GLOBALIZE_LABEL (FILE, NAME); \
|
||||
(*targetm.asm_out.globalize_label) (FILE, NAME); \
|
||||
ASM_OUTPUT_ALIGNED_LOCAL (FILE, NAME, SIZE, ALIGN); \
|
||||
} while (0)
|
||||
|
||||
|
|
|
@ -196,9 +196,8 @@ toc_section () \
|
|||
/* This is how to output a command to make the user-level label named NAME
|
||||
defined for reference from other files. */
|
||||
|
||||
#define ASM_GLOBALIZE_LABEL(FILE,NAME) \
|
||||
do { fputs ("\t.globl ", FILE); \
|
||||
RS6000_OUTPUT_BASENAME (FILE, NAME); putc ('\n', FILE);} while (0)
|
||||
/* Globalizing directive for a label. */
|
||||
#define GLOBAL_ASM_OP "\t.globl "
|
||||
|
||||
/* Output at beginning of assembler file.
|
||||
|
||||
|
|
|
@ -2632,7 +2632,7 @@ v850_output_aligned_bss (file, decl, name, size, align)
|
|||
int size;
|
||||
int align;
|
||||
{
|
||||
ASM_GLOBALIZE_LABEL (file, name);
|
||||
(*targetm.asm_out.globalize_label) (file, name);
|
||||
|
||||
switch (v850_get_data_area (decl))
|
||||
{
|
||||
|
|
|
@ -45,6 +45,7 @@ static void vms_asm_out_constructor PARAMS ((rtx, int));
|
|||
static void vms_asm_out_destructor PARAMS ((rtx, int));
|
||||
static void vms_select_section PARAMS ((tree, int, unsigned HOST_WIDE_INT));
|
||||
static void vms_encode_section_info PARAMS ((tree, int));
|
||||
static void vms_globalize_label PARAMS ((FILE *, const char *));
|
||||
#endif
|
||||
|
||||
/* Initialize the GCC target structure. */
|
||||
|
@ -59,6 +60,8 @@ static void vms_encode_section_info PARAMS ((tree, int));
|
|||
#define TARGET_ASM_SELECT_SECTION vms_select_section
|
||||
#undef TARGET_ENCODE_SECTION_INFO
|
||||
#define TARGET_ENCODE_SECTION_INFO vms_encode_section_info
|
||||
#undef TARGET_ASM_GLOBALIZE_LABEL
|
||||
#define TARGET_ASM_GLOBALIZE_LABEL vms_globalize_label
|
||||
#endif
|
||||
|
||||
struct gcc_target targetm = TARGET_INITIALIZER;
|
||||
|
@ -925,6 +928,17 @@ vms_encode_section_info (decl, first)
|
|||
if (DECL_EXTERNAL (decl) && TREE_PUBLIC (decl))
|
||||
SYMBOL_REF_FLAG (XEXP (DECL_RTL (decl), 0)) = 1;
|
||||
}
|
||||
|
||||
/* This is how to output a command to make the user-level label named NAME
|
||||
defined for reference from other files. */
|
||||
static void
|
||||
vms_globalize_label (stream, name)
|
||||
FILE *stream;
|
||||
const char *name;
|
||||
{
|
||||
default_globalize_label (stream, name);
|
||||
vms_check_external (NULL_TREE, name, 0);
|
||||
}
|
||||
#endif /* VMS_TARGET */
|
||||
|
||||
/* Additional support code for VMS host. */
|
||||
|
|
|
@ -90,16 +90,8 @@ Boston, MA 02111-1307, USA. */
|
|||
/* This macro definition sets up a default value for `main' to return. */
|
||||
#define DEFAULT_MAIN_RETURN c_expand_return (integer_one_node)
|
||||
|
||||
/* This is how to output a command to make the user-level label named NAME
|
||||
defined for reference from other files. */
|
||||
|
||||
#undef ASM_GLOBALIZE_LABEL
|
||||
#define ASM_GLOBALIZE_LABEL(FILE,NAME) \
|
||||
do { fputs (".globl ", FILE); \
|
||||
assemble_name (FILE, NAME); \
|
||||
fputs ("\n", FILE); \
|
||||
vms_check_external (NULL_TREE, NAME, 0); \
|
||||
} while (0)
|
||||
/* Globalizing directive for a label. */
|
||||
#define GLOBAL_ASM_OP ".globl "
|
||||
|
||||
/* Under VMS we write the actual size of the storage to be allocated even
|
||||
though the symbol is external. Although it is possible to give external
|
||||
|
|
|
@ -154,19 +154,6 @@ do { fputs (integer_asm_op (POINTER_SIZE / UNITS_PER_WORD, TRUE), FILE); \
|
|||
#define ASM_OUTPUT_LABELREF(FILE,NAME) asm_fprintf ((FILE), "%U%s", (NAME))
|
||||
#endif
|
||||
|
||||
/* A C statement (sans semicolon) to output to the stdio stream FILE
|
||||
some commands that will make the label NAME global; that is,
|
||||
available for reference from other files. */
|
||||
|
||||
#if !defined(ASM_GLOBALIZE_LABEL) && defined(GLOBAL_ASM_OP)
|
||||
#define ASM_GLOBALIZE_LABEL(FILE,NAME) \
|
||||
do { \
|
||||
fputs (GLOBAL_ASM_OP, (FILE)); \
|
||||
assemble_name ((FILE), (NAME)); \
|
||||
fputc ('\n', (FILE)); \
|
||||
} while (0)
|
||||
#endif
|
||||
|
||||
/* Allow target to print debug info labels specially. This is useful for
|
||||
VLIW targets, since debug info labels should go into the middle of
|
||||
instruction bundles instead of breaking them. */
|
||||
|
|
|
@ -6582,17 +6582,13 @@ nothing.
|
|||
You may wish to use @code{ASM_OUTPUT_SIZE_DIRECTIVE} and/or
|
||||
@code{ASM_OUTPUT_MEASURED_SIZE} in the definition of this macro.
|
||||
|
||||
@findex ASM_GLOBALIZE_LABEL
|
||||
@item ASM_GLOBALIZE_LABEL (@var{stream}, @var{name})
|
||||
A C statement (sans semicolon) to output to the stdio stream
|
||||
@deftypefn {Target Hook} void TARGET_ASM_GLOBALIZE_LABEL (FILE *@var{stream}, const char *@var{name})
|
||||
This target hook is a function to output to the stdio stream
|
||||
@var{stream} some commands that will make the label @var{name} global;
|
||||
that is, available for reference from other files. Use the expression
|
||||
@code{assemble_name (@var{stream}, @var{name})} to output the name
|
||||
itself; before and after that, output the additional assembler syntax
|
||||
for making that name global, and a newline.
|
||||
that is, available for reference from other files.
|
||||
|
||||
If you define @code{GLOBAL_ASM_OP}, a default definition is provided
|
||||
which is correct for most systems.
|
||||
The default implementation relies on a proper definition of
|
||||
@code{GLOBAL_ASM_OP}.
|
||||
|
||||
@findex ASM_WEAKEN_LABEL
|
||||
@item ASM_WEAKEN_LABEL (@var{stream}, @var{name})
|
||||
|
|
|
@ -122,7 +122,7 @@ default_eh_frame_section ()
|
|||
|
||||
data_section ();
|
||||
ASM_OUTPUT_ALIGN (asm_out_file, floor_log2 (PTR_SIZE));
|
||||
ASM_GLOBALIZE_LABEL (asm_out_file, IDENTIFIER_POINTER (label));
|
||||
(*targetm.asm_out.globalize_label) (asm_out_file, IDENTIFIER_POINTER (label));
|
||||
ASM_OUTPUT_LABEL (asm_out_file, IDENTIFIER_POINTER (label));
|
||||
#endif
|
||||
}
|
||||
|
@ -6122,7 +6122,7 @@ output_die_symbol (die)
|
|||
/* We make these global, not weak; if the target doesn't support
|
||||
.linkonce, it doesn't support combining the sections, so debugging
|
||||
will break. */
|
||||
ASM_GLOBALIZE_LABEL (asm_out_file, sym);
|
||||
(*targetm.asm_out.globalize_label) (asm_out_file, sym);
|
||||
|
||||
ASM_OUTPUT_LABEL (asm_out_file, sym);
|
||||
}
|
||||
|
|
|
@ -1965,7 +1965,7 @@ output_alternate_entry_point (file, insn)
|
|||
ASM_WEAKEN_LABEL (file, name);
|
||||
#endif
|
||||
case LABEL_GLOBAL_ENTRY:
|
||||
ASM_GLOBALIZE_LABEL (file, name);
|
||||
(*targetm.asm_out.globalize_label) (file, name);
|
||||
case LABEL_STATIC_ENTRY:
|
||||
#ifdef ASM_OUTPUT_TYPE_DIRECTIVE
|
||||
ASM_OUTPUT_TYPE_DIRECTIVE (file, name, "function");
|
||||
|
|
|
@ -54,3 +54,11 @@ hook_tree_int_void (a, b)
|
|||
int b ATTRIBUTE_UNUSED;
|
||||
{
|
||||
}
|
||||
|
||||
/* Generic hook that takes (FILE *, const char *) and does nothing. */
|
||||
void
|
||||
hook_FILEptr_constcharptr_void (a, b)
|
||||
FILE *a ATTRIBUTE_UNUSED;
|
||||
const char *b ATTRIBUTE_UNUSED;
|
||||
{
|
||||
}
|
||||
|
|
|
@ -26,5 +26,6 @@ bool hook_void_bool_false PARAMS ((void));
|
|||
bool hook_tree_bool_false PARAMS ((tree));
|
||||
void hook_tree_int_void PARAMS ((tree, int));
|
||||
void hook_void_void PARAMS ((void));
|
||||
void hook_FILEptr_constcharptr_void PARAMS ((FILE *, const char *));
|
||||
|
||||
#endif
|
||||
|
|
|
@ -306,9 +306,6 @@ extern void assemble_string PARAMS ((const char *, int));
|
|||
extern void assemble_external_libcall PARAMS ((rtx));
|
||||
#endif
|
||||
|
||||
/* Declare the label NAME global. */
|
||||
extern void assemble_global PARAMS ((const char *));
|
||||
|
||||
/* Assemble a label named NAME. */
|
||||
extern void assemble_label PARAMS ((const char *));
|
||||
extern void assemble_eh_label PARAMS ((const char *));
|
||||
|
@ -540,6 +537,7 @@ extern void default_elf_select_rtx_section PARAMS ((enum machine_mode, rtx,
|
|||
unsigned HOST_WIDE_INT));
|
||||
extern const char *default_strip_name_encoding PARAMS ((const char *));
|
||||
extern bool default_binds_local_p PARAMS ((tree));
|
||||
extern void default_globalize_label PARAMS ((FILE *, const char *));
|
||||
|
||||
/* Emit data for vtable gc for GNU binutils. */
|
||||
extern void assemble_vtable_entry PARAMS ((struct rtx_def *, HOST_WIDE_INT));
|
||||
|
|
|
@ -604,7 +604,7 @@ typedef char _Bool;
|
|||
MD_INIT_BUILTINS MD_EXPAND_BUILTIN ASM_OUTPUT_CONSTRUCTOR \
|
||||
ASM_OUTPUT_DESTRUCTOR SIGNED_CHAR_SPEC MAX_CHAR_TYPE_SIZE \
|
||||
WCHAR_UNSIGNED UNIQUE_SECTION SELECT_SECTION SELECT_RTX_SECTION \
|
||||
ENCODE_SECTION_INFO STRIP_NAME_ENCODING
|
||||
ENCODE_SECTION_INFO STRIP_NAME_ENCODING ASM_GLOBALIZE_LABEL
|
||||
|
||||
/* Other obsolete target macros, or macros that used to be in target
|
||||
headers and were not used, and may be obsolete or may never have
|
||||
|
|
|
@ -54,6 +54,10 @@ Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
|||
|
||||
#define TARGET_ASM_INTEGER default_assemble_integer
|
||||
|
||||
#ifndef TARGET_ASM_GLOBALIZE_LABEL
|
||||
#define TARGET_ASM_GLOBALIZE_LABEL default_globalize_label
|
||||
#endif
|
||||
|
||||
#define TARGET_ASM_FUNCTION_PROLOGUE default_function_pro_epilogue
|
||||
#define TARGET_ASM_FUNCTION_EPILOGUE default_function_pro_epilogue
|
||||
#define TARGET_ASM_FUNCTION_END_PROLOGUE no_asm_to_stream
|
||||
|
@ -140,6 +144,7 @@ Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
|||
TARGET_ASM_ALIGNED_INT_OP, \
|
||||
TARGET_ASM_UNALIGNED_INT_OP, \
|
||||
TARGET_ASM_INTEGER, \
|
||||
TARGET_ASM_GLOBALIZE_LABEL, \
|
||||
TARGET_ASM_FUNCTION_PROLOGUE, \
|
||||
TARGET_ASM_FUNCTION_END_PROLOGUE, \
|
||||
TARGET_ASM_FUNCTION_BEGIN_EPILOGUE, \
|
||||
|
|
|
@ -69,6 +69,9 @@ struct gcc_target
|
|||
and UNALIGNED_OP are NULL. */
|
||||
bool (* integer) PARAMS ((rtx x, unsigned int size, int aligned_p));
|
||||
|
||||
/* Output code that will globalize a label. */
|
||||
void (* globalize_label) PARAMS ((FILE *, const char *));
|
||||
|
||||
/* Output the assembler code for entry to a function. */
|
||||
void (* function_prologue) PARAMS ((FILE *, HOST_WIDE_INT));
|
||||
|
||||
|
|
30
gcc/varasm.c
30
gcc/varasm.c
|
@ -506,7 +506,7 @@ asm_output_bss (file, decl, name, size, rounded)
|
|||
const char *name;
|
||||
int size ATTRIBUTE_UNUSED, rounded;
|
||||
{
|
||||
ASM_GLOBALIZE_LABEL (file, name);
|
||||
(*targetm.asm_out.globalize_label) (file, name);
|
||||
bss_section ();
|
||||
#ifdef ASM_DECLARE_OBJECT_NAME
|
||||
last_assemble_variable_decl = decl;
|
||||
|
@ -534,7 +534,7 @@ asm_output_aligned_bss (file, decl, name, size, align)
|
|||
const char *name;
|
||||
int size, align;
|
||||
{
|
||||
ASM_GLOBALIZE_LABEL (file, name);
|
||||
(*targetm.asm_out.globalize_label) (file, name);
|
||||
bss_section ();
|
||||
ASM_OUTPUT_ALIGN (file, floor_log2 (align / BITS_PER_UNIT));
|
||||
#ifdef ASM_DECLARE_OBJECT_NAME
|
||||
|
@ -1754,15 +1754,6 @@ assemble_external_libcall (fun)
|
|||
#endif
|
||||
}
|
||||
|
||||
/* Declare the label NAME global. */
|
||||
|
||||
void
|
||||
assemble_global (name)
|
||||
const char *name ATTRIBUTE_UNUSED;
|
||||
{
|
||||
ASM_GLOBALIZE_LABEL (asm_out_file, name);
|
||||
}
|
||||
|
||||
/* Assemble a label named NAME. */
|
||||
|
||||
void
|
||||
|
@ -4548,7 +4539,7 @@ globalize_decl (decl)
|
|||
}
|
||||
#endif
|
||||
|
||||
ASM_GLOBALIZE_LABEL (asm_out_file, name);
|
||||
(*targetm.asm_out.globalize_label) (asm_out_file, name);
|
||||
}
|
||||
|
||||
/* Emit an assembler directive to make the symbol for DECL an alias to
|
||||
|
@ -5249,4 +5240,19 @@ default_binds_local_p (exp)
|
|||
return local_p;
|
||||
}
|
||||
|
||||
/* Default function to output code that will globalize a label. A
|
||||
target must define GLOBAL_ASM_OP or provide it's own function to
|
||||
globalize a label. */
|
||||
#ifdef GLOBAL_ASM_OP
|
||||
void
|
||||
default_globalize_label (stream, name)
|
||||
FILE * stream;
|
||||
const char *name;
|
||||
{
|
||||
fputs (GLOBAL_ASM_OP, stream);
|
||||
assemble_name (stream, name);
|
||||
putc ('\n', stream);
|
||||
}
|
||||
#endif /* GLOBAL_ASM_OP */
|
||||
|
||||
#include "gt-varasm.h"
|
||||
|
|
Loading…
Reference in New Issue