diff options
author | YamaArashi <shadow962@live.com> | 2016-03-06 16:42:52 -0800 |
---|---|---|
committer | YamaArashi <shadow962@live.com> | 2016-03-06 16:42:52 -0800 |
commit | 63aec4bbdd77671b92dafbe6cb6e2e14f7a6635b (patch) | |
tree | 82700456fa515afbff2adb6c91319a43596e959b | |
parent | ce590c846da59bd8d6fa3232689b776716c8c4af (diff) |
remove unused functions
-rwxr-xr-x | gcc/config/arm/telf.h | 1 | ||||
-rwxr-xr-x | gcc/rtl.h | 1 | ||||
-rwxr-xr-x | gcc/tree.h | 2 | ||||
-rwxr-xr-x | gcc/varasm.c | 50 |
4 files changed, 0 insertions, 54 deletions
diff --git a/gcc/config/arm/telf.h b/gcc/config/arm/telf.h index 1144597..8c5d6e0 100755 --- a/gcc/config/arm/telf.h +++ b/gcc/config/arm/telf.h @@ -214,7 +214,6 @@ extern int arm_valid_machine_decl_attribute(tree decl, tree attributes, tree att #define NAME__MAIN "__gccmain" #define SYMBOL__MAIN __gccmain -#define MAKE_DECL_ONE_ONLY(DECL) (DECL_WEAK (DECL) = 1) #define UNIQUE_SECTION_P(DECL) (DECL_ONE_ONLY (DECL)) #define UNIQUE_SECTION(DECL,RELOC) \ do { \ @@ -1484,7 +1484,6 @@ extern int set_dominates_use (int, int, int, rtx, rtx); /* In varasm.c */ extern void bss_section (void); extern int in_data_section (void); -extern int supports_one_only (void); /* In rtl.c */ extern void init_rtl (void); @@ -2233,8 +2233,6 @@ extern void fixup_signed_type (tree); /* varasm.c */ extern void make_decl_rtl (tree, char *, int); -extern void make_decl_one_only (tree); -extern int supports_one_only (void); extern void variable_section (tree, int); /* In fold-const.c */ diff --git a/gcc/varasm.c b/gcc/varasm.c index d8b62b8..00273bc 100755 --- a/gcc/varasm.c +++ b/gcc/varasm.c @@ -4180,53 +4180,3 @@ assemble_alias (decl, target) #endif #endif } - -/* This determines whether or not we support link-once semantics. */ -#ifndef SUPPORTS_ONE_ONLY -#ifdef MAKE_DECL_ONE_ONLY -#define SUPPORTS_ONE_ONLY 1 -#else -#define SUPPORTS_ONE_ONLY 0 -#endif -#endif - -/* Returns 1 if the target configuration supports defining public symbols - so that one of them will be chosen at link time instead of generating a - multiply-defined symbol error, whether through the use of weak symbols or - a target-specific mechanism for having duplicates discarded. */ - -int -supports_one_only () -{ - if (SUPPORTS_ONE_ONLY) - return 1; - return SUPPORTS_WEAK; -} - -/* Set up DECL as a public symbol that can be defined in multiple - translation units without generating a linker error. */ - -void -make_decl_one_only (decl) - tree decl; -{ - if (TREE_CODE (decl) != VAR_DECL && TREE_CODE (decl) != FUNCTION_DECL) - abort (); - - TREE_PUBLIC (decl) = 1; - - if (TREE_CODE (decl) == VAR_DECL - && (DECL_INITIAL (decl) == 0 || DECL_INITIAL (decl) == error_mark_node)) - DECL_COMMON (decl) = 1; - else if (SUPPORTS_ONE_ONLY) - { -#ifdef MAKE_DECL_ONE_ONLY - MAKE_DECL_ONE_ONLY (decl); -#endif - DECL_ONE_ONLY (decl) = 1; - } - else if (SUPPORTS_WEAK) - DECL_WEAK (decl) = 1; - else - abort (); -} |