summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDan McDonald <danmcd@joyent.com>2021-10-21 11:25:03 -0400
committerDan McDonald <danmcd@joyent.com>2021-10-21 11:25:03 -0400
commit8670ecf7cf83864d6cefc939dbe8d114948999d7 (patch)
treecf16607f0c8fd7345caa49e8932378b24eacfaad
parent316370e02fe2482e0dba16e2ea4b8aae4ca53edf (diff)
parentb3403853e80914bd0aade9b5b605da4878078173 (diff)
downloadillumos-joyent-8670ecf7cf83864d6cefc939dbe8d114948999d7.tar.gz
[illumos-gate merge]
commit b3403853e80914bd0aade9b5b605da4878078173 14127 ld(1) can double free when cleaning up commit 3873d743e5df219b4232c7efe3c4be24a673379f 14158 unused GCC versions should be removed from Makefile.master (etc.)
-rw-r--r--usr/src/Makefile.master35
-rw-r--r--usr/src/cmd/audio/audioconvert/Makefile1
-rw-r--r--usr/src/cmd/audio/utilities/Makefile1
-rw-r--r--usr/src/cmd/cmd-inet/usr.lib/mdnsd/Makefile3
-rw-r--r--usr/src/cmd/hal/Makefile.hal6
-rw-r--r--usr/src/cmd/latencytop/Makefile.com6
-rw-r--r--usr/src/cmd/make/Makefile.com1
-rw-r--r--usr/src/cmd/policykit/Makefile6
-rw-r--r--usr/src/cmd/sgs/include/libld.h1
-rw-r--r--usr/src/cmd/sgs/libelf/common/end.c44
-rw-r--r--usr/src/cmd/sgs/libld/common/args.c2
-rw-r--r--usr/src/cmd/sgs/libld/common/ldmain.c14
-rw-r--r--usr/src/cmd/sgs/libld/common/libs.c23
-rw-r--r--usr/src/cmd/sgs/tools/SUNWonld-README1
-rw-r--r--usr/src/lib/libnisdb/Makefile2
-rw-r--r--usr/src/lib/policykit/libpolkit/Makefile.com6
-rw-r--r--usr/src/tools/make/Makefile.com2
-rw-r--r--usr/src/uts/Makefile.uts23
18 files changed, 61 insertions, 116 deletions
diff --git a/usr/src/Makefile.master b/usr/src/Makefile.master
index bdf0ffdc44..0be396e61d 100644
--- a/usr/src/Makefile.master
+++ b/usr/src/Makefile.master
@@ -378,14 +378,8 @@ CCNOAUTOINLINE= \
-_gcc=-fno-inline-small-functions \
-_gcc=-fno-inline-functions-called-once \
-_gcc=-fno-ipa-cp \
- -_gcc7=-fno-ipa-icf \
- -_gcc8=-fno-ipa-icf \
- -_gcc9=-fno-ipa-icf \
- -_gcc10=-fno-ipa-icf \
- -_gcc7=-fno-clone-functions \
- -_gcc8=-fno-clone-functions \
- -_gcc9=-fno-clone-functions \
- -_gcc10=-fno-clone-functions
+ -_gcc=-fno-ipa-icf \
+ -_gcc=-fno-clone-functions
# GCC may put functions in different named sub-sections of .text based on
# their presumed calling frequency. At least in the kernel, where we actually
@@ -393,11 +387,7 @@ CCNOAUTOINLINE= \
#
# Since at present we don't benefit from this even in userland, we disable it globally,
# but the application of this may move into usr/src/uts/ in future.
-CCNOREORDER= \
- -_gcc7=-fno-reorder-functions \
- -_gcc8=-fno-reorder-functions \
- -_gcc9=-fno-reorder-functions \
- -_gcc10=-fno-reorder-functions
+CCNOREORDER= -_gcc=-fno-reorder-functions
#
# gcc has a rather aggressive optimization on by default that infers loop
@@ -406,11 +396,7 @@ CCNOREORDER= \
# strictest sense but also result in incorrect program behavior. We turn
# this optimization off, with extreme prejudice.
#
-CCNOAGGRESSIVELOOPS= \
- -_gcc7=-fno-aggressive-loop-optimizations \
- -_gcc8=-fno-aggressive-loop-optimizations \
- -_gcc9=-fno-aggressive-loop-optimizations \
- -_gcc10=-fno-aggressive-loop-optimizations
+CCNOAGGRESSIVELOOPS= -_gcc=-fno-aggressive-loop-optimizations
#
# Options to control which version of stack-protector we enable. This
@@ -433,11 +419,7 @@ CCNOAGGRESSIVELOOPS= \
# global CFLAGS at this time as it's being incrementally enabled
# throughout the build.
#
-STACKPROTECT_ = -_gcc4=-fstack-protector
-STACKPROTECT_ += -_gcc7=-fstack-protector-strong
-STACKPROTECT_ += -_gcc8=-fstack-protector-strong
-STACKPROTECT_ += -_gcc9=-fstack-protector-strong
-STACKPROTECT_ += -_gcc10=-fstack-protector-strong
+STACKPROTECT_ = -_gcc=-fstack-protector-strong
STACKPROTECT_strong = $(STACKPROTECT_)
STACKPROTECT_none =
@@ -525,12 +507,7 @@ CERRWARN += -_gcc=-Wno-missing-field-initializers
# Unfortunately, this option can misfire very easily and unfixably.
CERRWARN += -_gcc=-Wno-array-bounds
-# gcc4 lacks -Wno-maybe-uninitialized
-CNOWARN_UNINIT = -_gcc4=-Wno-uninitialized \
- -_gcc7=-Wno-maybe-uninitialized \
- -_gcc8=-Wno-maybe-uninitialized \
- -_gcc9=-Wno-maybe-uninitialized \
- -_gcc10=-Wno-maybe-uninitialized
+CNOWARN_UNINIT = -_gcc=-Wno-maybe-uninitialized
CERRWARN += -_smatch=-p=illumos_user
include $(SRC)/Makefile.smatch
diff --git a/usr/src/cmd/audio/audioconvert/Makefile b/usr/src/cmd/audio/audioconvert/Makefile
index 051b918766..3cdd2b4e0e 100644
--- a/usr/src/cmd/audio/audioconvert/Makefile
+++ b/usr/src/cmd/audio/audioconvert/Makefile
@@ -34,7 +34,6 @@ include ../../Makefile.cmd
INCLUDES += -I../include -I.
CPPFLAGS += $(INCLUDES)
-CCFLAGS += -_gcc4=-std=gnu++0x
PROGSRCS= convert.cc file.cc main.cc parse.cc
diff --git a/usr/src/cmd/audio/utilities/Makefile b/usr/src/cmd/audio/utilities/Makefile
index 4038386710..6d62590594 100644
--- a/usr/src/cmd/audio/utilities/Makefile
+++ b/usr/src/cmd/audio/utilities/Makefile
@@ -33,7 +33,6 @@ INCLUDES += -I../include
CPPFLAGS += $(INCLUDES)
-CCFLAGS += -_gcc4=-std=gnu++0x
CFLAGS += $(CCVERBOSE)
CERRWARN += $(CNOWARN_UNINIT)
CERRWARN += -_gcc=-Wno-unused-variable
diff --git a/usr/src/cmd/cmd-inet/usr.lib/mdnsd/Makefile b/usr/src/cmd/cmd-inet/usr.lib/mdnsd/Makefile
index a8c1280cc3..cdf783ecf9 100644
--- a/usr/src/cmd/cmd-inet/usr.lib/mdnsd/Makefile
+++ b/usr/src/cmd/cmd-inet/usr.lib/mdnsd/Makefile
@@ -47,8 +47,7 @@ include ../../../Makefile.cmd
CERRWARN += -_gcc=-Wno-unused-variable
CERRWARN += -_gcc=-Wno-implicit-function-declaration
-CERRWARN += -_gcc7=-Wno-expansion-to-defined
-CERRWARN += -_gcc10=-Wno-expansion-to-defined
+CERRWARN += -_gcc=-Wno-expansion-to-defined
CERRWARN += $(CNOWARN_UNINIT)
# not linted
diff --git a/usr/src/cmd/hal/Makefile.hal b/usr/src/cmd/hal/Makefile.hal
index 1b353b62df..d42d5b1449 100644
--- a/usr/src/cmd/hal/Makefile.hal
+++ b/usr/src/cmd/hal/Makefile.hal
@@ -75,11 +75,5 @@ CERRWARN += -_gcc=-Wno-parentheses
CERRWARN += -_gcc=-Wno-address
CERRWARN += -_gcc=-Wno-unused-function
-# glib2 >= 2.62 suppresses warnings about deprecated declarations in header
-# files using pragma "GCC diagnostic ignored \"-Wdeprecated-declarations\""
-# This is not supported before GCC 4.6 so just globally suppress these
-# warnings under the shadow compiler
-CERRWARN += -_gcc4=-Wno-deprecated-declarations
-
# not linted
SMATCH=off
diff --git a/usr/src/cmd/latencytop/Makefile.com b/usr/src/cmd/latencytop/Makefile.com
index 08b826b8d7..0938ca4bb4 100644
--- a/usr/src/cmd/latencytop/Makefile.com
+++ b/usr/src/cmd/latencytop/Makefile.com
@@ -36,12 +36,6 @@ CFLAGS64 += $(CCVERBOSE)
CERRWARN += $(CNOWARN_UNINIT)
-# glib2 >= 2.62 suppresses warnings about deprecated declarations in header
-# files using pragma "GCC diagnostic ignored \"-Wdeprecated-declarations\""
-# This is not supported before GCC 4.6 so just globally suppress these
-# warnings under the shadow compiler
-CERRWARN += -_gcc4=-Wno-deprecated-declarations
-
# smatch has problems parsing the glib header files
SMATCH=off
diff --git a/usr/src/cmd/make/Makefile.com b/usr/src/cmd/make/Makefile.com
index fc76730f2a..dcc587439e 100644
--- a/usr/src/cmd/make/Makefile.com
+++ b/usr/src/cmd/make/Makefile.com
@@ -14,7 +14,6 @@
MAKE_INCLUDE= $(SRC)/cmd/make/include
CFLAGS += $(CCVERBOSE)
CPPFLAGS += -I$(MAKE_INCLUDE) $(MAKE_DEFS)
-CCFLAGS += -_gcc4=-std=gnu++0x
# So that it's set even for the libraries we build
TEXT_DOMAIN = SUNW_OST_OSCMD
diff --git a/usr/src/cmd/policykit/Makefile b/usr/src/cmd/policykit/Makefile
index ac31801139..c2d4a1c3a7 100644
--- a/usr/src/cmd/policykit/Makefile
+++ b/usr/src/cmd/policykit/Makefile
@@ -43,12 +43,6 @@ CSTD = $(CSTD_GNU99)
CERRWARN += -_gcc=-Wno-unused-variable
CERRWARN += -_gcc=-Wno-unused-function
-# glib2 >= 2.62 suppresses warnings about deprecated declarations in header
-# files using pragma "GCC diagnostic ignored \"-Wdeprecated-declarations\""
-# This is not supported before GCC 4.6 so just globally suppress these
-# warnings under the shadow compiler
-CERRWARN += -_gcc4=-Wno-deprecated-declarations
-
# smatch has problems parsing the glib header files
SMATCH=off
diff --git a/usr/src/cmd/sgs/include/libld.h b/usr/src/cmd/sgs/include/libld.h
index a48cdaf553..11a73d949a 100644
--- a/usr/src/cmd/sgs/include/libld.h
+++ b/usr/src/cmd/sgs/include/libld.h
@@ -1524,6 +1524,7 @@ typedef struct ar_desc {
dev_t ad_stdev; /* device id and inode number for */
ino_t ad_stino; /* multiple inclusion checks */
ofl_flag_t ad_flags; /* archive specific cmd line flags */
+ Boolean ad_allextract; /* archive has been allextract'ed */
} Ar_desc;
/*
diff --git a/usr/src/cmd/sgs/libelf/common/end.c b/usr/src/cmd/sgs/libelf/common/end.c
index 037f26f87d..b8b14563e5 100644
--- a/usr/src/cmd/sgs/libelf/common/end.c
+++ b/usr/src/cmd/sgs/libelf/common/end.c
@@ -25,7 +25,7 @@
*/
/* Copyright (c) 1988 AT&T */
-/* All Rights Reserved */
+/* All Rights Reserved */
#include <ar.h>
#include <stdlib.h>
@@ -34,14 +34,14 @@
#include "member.h"
int
-elf_end(Elf * elf)
+elf_end(Elf *elf)
{
- Elf_Scn * s;
- Dnode * d;
- Elf_Void * trail = 0;
- int rc;
+ Elf_Scn *s;
+ Dnode *d;
+ Elf_Void *trail = NULL;
+ int rc;
- if (elf == 0)
+ if (elf == NULL)
return (0);
ELFWLOCK(elf)
@@ -52,22 +52,22 @@ elf_end(Elf * elf)
}
while (elf->ed_activ == 0) {
- for (s = elf->ed_hdscn; s != 0; s = s->s_next) {
+ for (s = elf->ed_hdscn; s != NULL; s = s->s_next) {
if (s->s_myflags & SF_ALLOC) {
- if (trail != 0)
+ if (trail != NULL)
free(trail);
trail = (Elf_Void *)s;
}
if ((s->s_myflags & SF_READY) == 0)
continue;
- for (d = s->s_hdnode; d != 0; ) {
+ for (d = s->s_hdnode; d != NULL; ) {
register Dnode *t;
- if (d->db_buf != 0)
+ if (d->db_buf != NULL)
free(d->db_buf);
- if ((t = d->db_raw) != 0) {
- if (t->db_buf != 0)
+ if ((t = d->db_raw) != NULL) {
+ if (t->db_buf != NULL)
free(t->db_buf);
if (t->db_myflags & DBF_ALLOC)
free(t);
@@ -78,16 +78,17 @@ elf_end(Elf * elf)
d = t;
}
}
- if (trail != 0) {
+ if (trail != NULL) {
free(trail);
- trail = 0;
+ trail = NULL;
}
{
register Memlist *l;
register Memident *i;
- for (l = elf->ed_memlist; l; l = (Memlist *)trail) {
+ for (l = elf->ed_memlist; l != NULL;
+ l = (Memlist *)trail) {
trail = (Elf_Void *)l->m_next;
for (i = (Memident *)(l + 1); i < l->m_free;
i++)
@@ -114,17 +115,20 @@ elf_end(Elf * elf)
* we don't release it at all, it's not ours to release.
*/
- if (elf->ed_parent == 0) {
- if (elf->ed_vm != 0)
+ if (elf->ed_parent == NULL) {
+ if (elf->ed_vm != NULL)
free(elf->ed_vm);
else if ((elf->ed_myflags & EDF_MEMORY) == 0)
_elf_unmap(elf->ed_image, elf->ed_imagesz);
}
+
trail = (Elf_Void *)elf;
elf = elf->ed_parent;
ELFUNLOCK(trail)
free(trail);
- if (elf == 0)
+ trail = NULL;
+
+ if (elf == NULL)
break;
/*
* If parent is inactive we close
@@ -134,7 +138,7 @@ elf_end(Elf * elf)
--elf->ed_activ;
}
- if (elf) {
+ if (elf != NULL) {
ELFUNLOCK(elf)
}
diff --git a/usr/src/cmd/sgs/libld/common/args.c b/usr/src/cmd/sgs/libld/common/args.c
index f1ad264438..2dfa6e4ca3 100644
--- a/usr/src/cmd/sgs/libld/common/args.c
+++ b/usr/src/cmd/sgs/libld/common/args.c
@@ -276,7 +276,7 @@ ld_rescan_archives(Ofl_desc *ofl, int isgrp, int end_arg_ndx)
* If this archive was processed with -z allextract,
* then all members have already been extracted.
*/
- if (adp->ad_elf == NULL)
+ if (adp->ad_allextract == TRUE)
continue;
/*
diff --git a/usr/src/cmd/sgs/libld/common/ldmain.c b/usr/src/cmd/sgs/libld/common/ldmain.c
index f77e6ac8b7..650e2d63a8 100644
--- a/usr/src/cmd/sgs/libld/common/ldmain.c
+++ b/usr/src/cmd/sgs/libld/common/ldmain.c
@@ -542,9 +542,19 @@ ld_ofl_cleanup(Ofl_desc *ofl)
Ar_aux *aup;
Elf_Arsym *arsym;
+ /*
+ * Free up member information for normally processed archives.
+ * Archives processed under -z allextract have no member
+ * information or symbol table, and members have already been
+ * dealt with as input files.
+ */
+ if (adp->ad_allextract == TRUE)
+ continue;
+
for (arsym = adp->ad_start, aup = adp->ad_aux;
- arsym->as_name; ++arsym, ++aup) {
- if ((aup->au_mem) && (aup->au_mem != FLG_ARMEM_PROC)) {
+ (arsym->as_name != NULL); ++arsym, ++aup) {
+ if ((aup->au_mem != NULL) &&
+ (aup->au_mem != FLG_ARMEM_PROC)) {
(void) elf_end(aup->au_mem->am_elf);
/*
diff --git a/usr/src/cmd/sgs/libld/common/libs.c b/usr/src/cmd/sgs/libld/common/libs.c
index ebdb686462..f43b8f90d2 100644
--- a/usr/src/cmd/sgs/libld/common/libs.c
+++ b/usr/src/cmd/sgs/libld/common/libs.c
@@ -49,11 +49,11 @@
* If the archive member simply contains another tentative definition,
* or a defined function symbol, then it will not be used.
*
- * ii. A symbol reference may define a hidden or protected visibility. The
+ * ii. A symbol reference may define a hidden or protected visibility. The
* reference can only be bound to a definition within a relocatable object
- * for this restricted visibility to be satisfied. If the archive member
- * provides a definition of the same symbol type, this definition is
- * taken. The visibility of the defined symbol is irrelevant, as the most
+ * for this restricted visibility to be satisfied. If the archive member
+ * provides a definition of the same symbol type, this definition is
+ * taken. The visibility of the defined symbol is irrelevant, as the most
* restrictive visibility of the reference and the definition will be
* applied to the final symbol.
*
@@ -66,7 +66,7 @@ process_member(Ar_mem *amp, const char *name, Sym_desc *sdp, Ofl_desc *ofl)
{
Sym *syms, *osym = sdp->sd_sym;
Xword symn, cnt;
- char *strs;
+ char *strs;
/*
* Find the first symbol table in the archive member, obtain its
@@ -214,6 +214,7 @@ ld_ar_setup(const char *name, Elf *elf, Ofl_desc *ofl)
adp->ad_name = name;
adp->ad_elf = elf;
adp->ad_start = start;
+ adp->ad_allextract = FALSE;
if (start) {
adp->ad_aux = libld_calloc(sizeof (Ar_aux), number);
if (adp->ad_aux == NULL)
@@ -796,16 +797,13 @@ ar_extract_all(const char *name, int fd, Ar_desc *adp, Ofl_desc *ofl,
}
*found = TRUE;
-
}
/*
- * As this archive was extracted by -z allextract, the ar_aux table
- * and elf descriptor can be freed. Set ad_elf to NULL to mark the
- * archive is completely processed.
+ * Mark this as having been completely processed, so we don't have do
+ * work harder than necessary.
*/
- (void) elf_end(adp->ad_elf);
- adp->ad_elf = NULL;
+ adp->ad_allextract = TRUE;
return (TRUE);
}
@@ -846,7 +844,7 @@ ld_process_archive(const char *name, int fd, Ar_desc *adp, Ofl_desc *ofl)
* If this archive was processed with -z allextract, then all members
* have already been extracted.
*/
- if (adp->ad_elf == NULL)
+ if (adp->ad_allextract == TRUE)
return (TRUE);
if (ofl->ofl_flags1 & FLG_OF1_ALLEXRT) {
@@ -870,6 +868,5 @@ ld_process_archive(const char *name, int fd, Ar_desc *adp, Ofl_desc *ofl)
conv_reject_desc(&rej, &rej_buf, ld_targ.t_m.m_mach));
}
-
return (TRUE);
}
diff --git a/usr/src/cmd/sgs/tools/SUNWonld-README b/usr/src/cmd/sgs/tools/SUNWonld-README
index 695c545719..c0f2b139d1 100644
--- a/usr/src/cmd/sgs/tools/SUNWonld-README
+++ b/usr/src/cmd/sgs/tools/SUNWonld-README
@@ -1676,3 +1676,4 @@ Bugid Risk Synopsis
14090 ld(1) could use a normal allocator
14090 backout: turns over big rocks, discovers big bugs
14152 ld(1) should be more careful about empty alists
+14127 ld(1) can double free when cleaning up
diff --git a/usr/src/lib/libnisdb/Makefile b/usr/src/lib/libnisdb/Makefile
index 3aef8d0739..d09ddee226 100644
--- a/usr/src/lib/libnisdb/Makefile
+++ b/usr/src/lib/libnisdb/Makefile
@@ -175,8 +175,6 @@ CCERRWARN += -_gcc=-Wno-return-type
CCERRWARN += -_gcc=-Wno-uninitialized
CCERRWARN += -_gcc7=-Wno-nonnull-compare
-CCERRWARN += -_gcc8=-Wno-nonnull-compare
-CCERRWARN += -_gcc9=-Wno-nonnull-compare
# not linted
SMATCH=off
diff --git a/usr/src/lib/policykit/libpolkit/Makefile.com b/usr/src/lib/policykit/libpolkit/Makefile.com
index abb0c6891f..55360585c2 100644
--- a/usr/src/lib/policykit/libpolkit/Makefile.com
+++ b/usr/src/lib/policykit/libpolkit/Makefile.com
@@ -43,12 +43,6 @@ CPPFLAGS += -DPACKAGE_LOCALE_DIR=\"/usr/lib/locale\"
ROOTMAJLINK = $(ROOTLIBDIR)/$(LIBRARY:.a=.so)$(VERS_MAJ)
-# glib2 >= 2.62 suppresses warnings about deprecated declarations in header
-# files using pragma "GCC diagnostic ignored \"-Wdeprecated-declarations\""
-# This is not supported before GCC 4.6 so just globally suppress these
-# warnings under the shadow compiler
-CERRWARN += -_gcc4=-Wno-deprecated-declarations
-
# smatch has problems parsing the glib header files
SMATCH=off
diff --git a/usr/src/tools/make/Makefile.com b/usr/src/tools/make/Makefile.com
index 8fbe1bc1b4..8cebd2199d 100644
--- a/usr/src/tools/make/Makefile.com
+++ b/usr/src/tools/make/Makefile.com
@@ -18,6 +18,6 @@ CC = $(NATIVECC)
CCC = $(NATIVECCC)
CFLAGS = $(NATIVE_CFLAGS)
CFLAGS += $(CCVERBOSE)
-CCFLAGS = $(NATIVE_CCFLAGS) -_gcc4=-std=gnu++0x
+CCFLAGS = $(NATIVE_CCFLAGS)
CPPFLAGS = -I$(MAKE_INCLUDE) $(MAKE_DEFS)
CCNEEDED = $(NATIVECCNEEDED)
diff --git a/usr/src/uts/Makefile.uts b/usr/src/uts/Makefile.uts
index 02c3a31ba9..b58c1e5809 100644
--- a/usr/src/uts/Makefile.uts
+++ b/usr/src/uts/Makefile.uts
@@ -172,12 +172,7 @@ CERRWARN += -_gcc=-Wno-unknown-pragmas
CERRWARN += -_gcc=-Wno-unused-parameter
CERRWARN += -_gcc=-Wno-missing-field-initializers
-# gcc4 lacks -Wno-maybe-uninitialized
-CNOWARN_UNINIT = -_gcc4=-Wno-uninitialized \
- -_gcc7=-Wno-maybe-uninitialized \
- -_gcc8=-Wno-maybe-uninitialized \
- -_gcc9=-Wno-maybe-uninitialized \
- -_gcc10=-Wno-maybe-uninitialized
+CNOWARN_UNINIT = -_gcc=-Wno-maybe-uninitialized
# DEBUG v. -nd make for frequent unused variables, empty conditions, etc. in
# -nd builds
@@ -206,22 +201,12 @@ CFLAGS_uts_i386 += -_gcc8=-mindirect-branch-register
# Ensure that the standard function prologue remains at the very start
# of a function, so DTrace fbt will instrument the right place.
#
-CFLAGS_uts_i386 += -_gcc7=-fno-shrink-wrap
-CFLAGS_uts_i386 += -_gcc8=-fno-shrink-wrap
-CFLAGS_uts_i386 += -_gcc9=-fno-shrink-wrap
-CFLAGS_uts_i386 += -_gcc10=-fno-shrink-wrap
-
+CFLAGS_uts_i386 += -_gcc=-fno-shrink-wrap
#
# retpoline support
#
-CFLAGS_uts_i386 += -_gcc7=-mindirect-branch=thunk-extern
-CFLAGS_uts_i386 += -_gcc7=-mindirect-branch-register
-CFLAGS_uts_i386 += -_gcc8=-mindirect-branch=thunk-extern
-CFLAGS_uts_i386 += -_gcc8=-mindirect-branch-register
-CFLAGS_uts_i386 += -_gcc9=-mindirect-branch=thunk-extern
-CFLAGS_uts_i386 += -_gcc9=-mindirect-branch-register
-CFLAGS_uts_i386 += -_gcc10=-mindirect-branch=thunk-extern
-CFLAGS_uts_i386 += -_gcc10=-mindirect-branch-register
+CFLAGS_uts_i386 += -_gcc=-mindirect-branch=thunk-extern
+CFLAGS_uts_i386 += -_gcc=-mindirect-branch-register
CSTD = $(CSTD_GNU99)