From ab7b56730bc193083d0a778b79ca5be0390e17d5 Mon Sep 17 00:00:00 2001 From: Trevor Saunders Date: Sun, 15 Nov 2015 00:17:56 +0000 Subject: [PATCH] always define TARGET_PECOFF gcc/ChangeLog: 2015-11-14 Trevor Saunders * config/i386/i386.h (TARGET_PECOFF): Remove define. * defaults.h (TARGET_PECOFF): New default definition. * varasm.c (handle_vtv_comdat_section): Adjust. gcc/cp/ChangeLog: 2015-11-14 Trevor Saunders * vtable-class-hierarchy.c (vtv_generate_init_routine): Adjust. From-SVN: r230391 --- gcc/ChangeLog | 6 ++++++ gcc/config/i386/i386.h | 3 --- gcc/cp/ChangeLog | 4 ++++ gcc/cp/vtable-class-hierarchy.c | 8 -------- gcc/defaults.h | 4 ++++ gcc/varasm.c | 6 +++--- 6 files changed, 17 insertions(+), 14 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 3ac6d3f6382..2254c009260 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2015-11-14 Trevor Saunders + + * config/i386/i386.h (TARGET_PECOFF): Remove define. + * defaults.h (TARGET_PECOFF): New default definition. + * varasm.c (handle_vtv_comdat_section): Adjust. + 2015-11-14 Trevor Saunders * defaults.h: New definition of SDB_DEBUGGING_INFO. diff --git a/gcc/config/i386/i386.h b/gcc/config/i386/i386.h index 3d5b2b25ced..829c3f418b5 100644 --- a/gcc/config/i386/i386.h +++ b/gcc/config/i386/i386.h @@ -595,9 +595,6 @@ extern tree x86_mfence; /* This is re-defined by cygming.h. */ #define TARGET_SEH 0 -/* This is re-defined by cygming.h. */ -#define TARGET_PECOFF 0 - /* The default abi used by target. */ #define DEFAULT_ABI SYSV_ABI diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index b154453dde1..1b052dca87a 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,3 +1,7 @@ +2015-11-14 Trevor Saunders + + * vtable-class-hierarchy.c (vtv_generate_init_routine): Adjust. + 2015-11-14 Jason Merrill PR bootstrap/68346 diff --git a/gcc/cp/vtable-class-hierarchy.c b/gcc/cp/vtable-class-hierarchy.c index 752345d7ea4..97481fc0c64 100644 --- a/gcc/cp/vtable-class-hierarchy.c +++ b/gcc/cp/vtable-class-hierarchy.c @@ -1182,11 +1182,7 @@ vtv_generate_init_routine (void) TREE_STATIC (vtv_fndecl) = 1; TREE_USED (vtv_fndecl) = 1; DECL_PRESERVE_P (vtv_fndecl) = 1; -#if defined (TARGET_PECOFF) if (flag_vtable_verify == VTV_PREINIT_PRIORITY && !TARGET_PECOFF) -#else - if (flag_vtable_verify == VTV_PREINIT_PRIORITY) -#endif DECL_STATIC_CONSTRUCTOR (vtv_fndecl) = 0; gimplify_function_tree (vtv_fndecl); @@ -1194,11 +1190,7 @@ vtv_generate_init_routine (void) symtab->process_new_functions (); -#if defined (TARGET_PECOFF) if (flag_vtable_verify == VTV_PREINIT_PRIORITY && !TARGET_PECOFF) -#else - if (flag_vtable_verify == VTV_PREINIT_PRIORITY) -#endif assemble_vtv_preinit_initializer (vtv_fndecl); } diff --git a/gcc/defaults.h b/gcc/defaults.h index ddda89a7e14..eca624ca1be 100644 --- a/gcc/defaults.h +++ b/gcc/defaults.h @@ -1301,6 +1301,10 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see #define REVERSE_CONDITION(code, mode) reverse_condition (code) #endif +#ifndef TARGET_PECOFF +#define TARGET_PECOFF 0 +#endif + #ifdef GCC_INSN_FLAGS_H /* Dependent default target macro definitions diff --git a/gcc/varasm.c b/gcc/varasm.c index ec6aabf3d8e..31411101267 100644 --- a/gcc/varasm.c +++ b/gcc/varasm.c @@ -7793,7 +7793,7 @@ handle_vtv_comdat_section (section *sect, const_tree decl ATTRIBUTE_UNUSED) | SECTION_LINKONCE, DECL_NAME (decl)); in_section = sect; -#elif defined (TARGET_PECOFF) +#else /* Neither OBJECT_FORMAT_PE, nor OBJECT_FORMAT_COFF is set here. Therefore the following check is used. In case a the target is PE or COFF a comdat group section @@ -7820,8 +7820,8 @@ handle_vtv_comdat_section (section *sect, const_tree decl ATTRIBUTE_UNUSED) DECL_NAME (decl)); in_section = sect; } -#else - switch_to_section (sect); + else + switch_to_section (sect); #endif } -- 2.30.2