From d02d06a6da4f4ec4224f3cc1f1a85f294139d4c6 Mon Sep 17 00:00:00 2001 From: midipix Date: Sat, 2 Feb 2019 12:08:04 -0500 Subject: midipix targets: generate the .got entry for default & hidden visibility syms. --- gcc/config/i386/midipix.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'gcc/config') diff --git a/gcc/config/i386/midipix.c b/gcc/config/i386/midipix.c index 5f4fe5145..6ba5ee8b9 100644 --- a/gcc/config/i386/midipix.c +++ b/gcc/config/i386/midipix.c @@ -134,15 +134,17 @@ void midipix_asm_generate_internal_label ( static void midipix_pe_create_got_entry(FILE * stream, const char * name, tree decl) { + int visibility; + const char * ptrsize = TARGET_64BIT ? winnt_ptrsize_quad : winnt_ptrsize_long; - if (decl->decl_with_vis.visibility == VISIBILITY_DEFAULT) - if (default_visibility != VISIBILITY_DEFAULT) - return; + visibility = (decl->decl_with_vis.visibility == VISIBILITY_DEFAULT) + ? default_visibility + : decl->decl_with_vis.visibility; - if (decl->decl_with_vis.visibility != VISIBILITY_DEFAULT) + if ((visibility == VISIBILITY_PROTECTED) || (visibility == VISIBILITY_INTERNAL)) return; fputs("\n",stream); -- cgit v1.2.3