1
0
mirror of https://sourceware.org/git/glibc.git synced 2025-12-06 12:01:08 +03:00

Annotate swtich fall-through

The clang default to warning for missing fall-through and it does
not support all comment-like annotation that gcc does.  Use C23
[[fallthrough]] annotation instead.
proper attribute instead.

Reviewed-by: Collin Funk <collin.funk1@gmail.com>
This commit is contained in:
Adhemerval Zanella
2025-10-28 14:08:30 -03:00
parent 543ddd628f
commit 970364dac0
41 changed files with 75 additions and 67 deletions

View File

@@ -134,7 +134,7 @@ _dl_exception_create_format (struct dl_exception *exception, const char *objname
++p; ++p;
break; break;
} }
/* Fall through. */ [[fallthrough]];
case 'x': case 'x':
length += INT_WIDTH / 4; length += INT_WIDTH / 4;
break; break;
@@ -219,7 +219,7 @@ _dl_exception_create_format (struct dl_exception *exception, const char *objname
++p; ++p;
break; break;
} }
/* FALLTHROUGH */ [[fallthrough]];
default: default:
_dl_fatal_printf ("Fatal error:" _dl_fatal_printf ("Fatal error:"
" invalid format in exception string\n"); " invalid format in exception string\n");

View File

@@ -136,7 +136,7 @@ _dl_find_object_from_map (struct link_map *l,
atomic_store_relaxed (&result->sframe, atomic_store_relaxed (&result->sframe,
(void *) (ph->p_vaddr + l->l_addr)); (void *) (ph->p_vaddr + l->l_addr));
read_seg |= 2; read_seg |= 2;
/* Fall through. */ [[fallthrough]];
default: default:
break; break;
} }

View File

@@ -490,7 +490,7 @@ do_lookup_x (const char *undef_name, unsigned int new_hash,
} }
break; break;
} }
/* FALLTHROUGH */ [[fallthrough]];
case STB_GLOBAL: case STB_GLOBAL:
/* Global definition. Just what we need. */ /* Global definition. Just what we need. */
result->s = sym; result->s = sym;

View File

@@ -1151,7 +1151,7 @@ parse_conf_include (const char *config_file, unsigned int lineno,
case GLOB_NOSPACE: case GLOB_NOSPACE:
errno = ENOMEM; errno = ENOMEM;
/* Fall through. */ [[fallthrough]];
case GLOB_ABORTED: case GLOB_ABORTED:
if (opt_verbose) if (opt_verbose)
error (0, errno, _("%s:%u: cannot read directory %s"), error (0, errno, _("%s:%u: cannot read directory %s"),

View File

@@ -2755,10 +2755,10 @@ print_statistics_item (const char *title, hp_timing_t time,
{ {
case 3: case 3:
*wp++ = *cp++; *wp++ = *cp++;
/* Fall through. */ [[fallthrough]];
case 2: case 2:
*wp++ = *cp++; *wp++ = *cp++;
/* Fall through. */ [[fallthrough]];
case 1: case 1:
*wp++ = '.'; *wp++ = '.';
*wp++ = *cp++; *wp++ = *cp++;

View File

@@ -47,7 +47,7 @@ find_suffix (char *s)
{ {
case '/': case '/':
slash_count++; slash_count++;
/* Fallthrough */ [[fallthrough]];
case ',': case ',':
suffix_term = &s[i]; suffix_term = &s[i];
} }

View File

@@ -220,7 +220,7 @@ ucs4_to_cns11643 (uint32_t wch, unsigned char *s, size_t avail)
if (cp[0] != '\0') if (cp[0] != '\0')
break; break;
/* Let's try the other planes. */ /* Let's try the other planes. */
/* Fall through. */ [[fallthrough]];
case 0x3400 ... 0x4dff: case 0x3400 ... 0x4dff:
case 0x9f9d ... 0x9fa5: case 0x9f9d ... 0x9fa5:
/* Let's try the other planes. */ /* Let's try the other planes. */

View File

@@ -125,7 +125,7 @@ next:
case DEFAULT: case DEFAULT:
usedefault = 1; usedefault = 1;
/* FALL THROUGH */ [[fallthrough]];
case MACHINE: case MACHINE:
if (!usedefault) { if (!usedefault) {

View File

@@ -159,7 +159,8 @@ $(objpfx)tst-gettext6.out: $(objpfx)tst-gettext.out
CPPFLAGS += -D'LOCALEDIR="$(localedir)"' \ CPPFLAGS += -D'LOCALEDIR="$(localedir)"' \
-D'LOCALE_ALIAS_PATH="$(localedir)"' \ -D'LOCALE_ALIAS_PATH="$(localedir)"' \
-Wno-unused-but-set-variable -Wno-unused-but-set-variable \
-Wno-implicit-fallthrough
BISONFLAGS = --yacc --no-lines --name-prefix=__gettext --output BISONFLAGS = --yacc --no-lines --name-prefix=__gettext --output
$(inst_localedir)/locale.alias: locale.alias $(+force) $(inst_localedir)/locale.alias: locale.alias $(+force)

View File

@@ -104,19 +104,19 @@ hash (register const char *str, register size_t len)
switch (hval) switch (hval)
{ {
default: default:
hval += asso_values[(unsigned char)str[8]]; hval += asso_values[(unsigned char)str[8]];
/*FALLTHROUGH*/ [[fallthrough]];
case 8: case 8:
case 7: case 7:
case 6: case 6:
case 5: case 5:
hval += asso_values[(unsigned char)str[4]]; hval += asso_values[(unsigned char)str[4]];
/*FALLTHROUGH*/ [[fallthrough]];
case 4: case 4:
case 3: case 3:
case 2: case 2:
hval += asso_values[(unsigned char)str[1]]; hval += asso_values[(unsigned char)str[1]];
/*FALLTHROUGH*/ [[fallthrough]];
case 1: case 1:
hval += asso_values[(unsigned char)str[0]]; hval += asso_values[(unsigned char)str[0]];
break; break;

View File

@@ -548,7 +548,7 @@ character sets with locking states are not supported"));
state = 4; state = 4;
continue; continue;
} }
/* FALLTHROUGH */ [[fallthrough]] ;
case 5: case 5:
if (nowtok != tok_charcode) if (nowtok != tok_charcode)
@@ -712,7 +712,7 @@ only WIDTH definitions are allowed to follow the CHARMAP definition"));
state = 95; state = 95;
continue; continue;
} }
/* Fall through. */ [[fallthrough]] ;
case 96: case 96:
if (nowtok != tok_number) if (nowtok != tok_number)

View File

@@ -105,18 +105,18 @@ hash (register const char *str, register size_t len)
{ {
default: default:
hval += asso_values[(unsigned char)str[8]]; hval += asso_values[(unsigned char)str[8]];
/*FALLTHROUGH*/ [[fallthrough]] ;
case 8: case 8:
case 7: case 7:
case 6: case 6:
case 5: case 5:
hval += asso_values[(unsigned char)str[4]]; hval += asso_values[(unsigned char)str[4]];
/*FALLTHROUGH*/ [[fallthrough]] ;
case 4: case 4:
case 3: case 3:
case 2: case 2:
hval += asso_values[(unsigned char)str[1]]; hval += asso_values[(unsigned char)str[1]];
/*FALLTHROUGH*/ [[fallthrough]] ;
case 1: case 1:
hval += asso_values[(unsigned char)str[0]]; hval += asso_values[(unsigned char)str[0]];
break; break;

View File

@@ -206,7 +206,7 @@ argument to <%s> must be a single character"),
/* Otherwise we start reading the character definitions. */ /* Otherwise we start reading the character definitions. */
state = 2; state = 2;
/* FALLTHROUGH */ [[fallthrough]] ;
case 2: case 2:
/* We are now are in the body. Each line /* We are now are in the body. Each line
@@ -254,7 +254,7 @@ argument to <%s> must be a single character"),
state = 4; state = 4;
continue; continue;
} }
/* FALLTHROUGH */ [[fallthrough]] ;
case 5: case 5:
/* We expect a value of the form <Uxxxx> or <Uxxxxxxxx> where /* We expect a value of the form <Uxxxx> or <Uxxxxxxxx> where

View File

@@ -389,7 +389,7 @@ __mcheck_initialize (void (*func) (enum mcheck_status), bool in_pedantic)
case -1: case -1:
/* Called before the first malloc was called. */ /* Called before the first malloc was called. */
__debug_free (__debug_malloc (0)); __debug_free (__debug_malloc (0));
/* FALLTHROUGH */ [[fallthrough]] ;
case 0: case 0:
/* Called through the initializer hook. */ /* Called through the initializer hook. */
__malloc_debug_enable (MALLOC_MCHECK_HOOK); __malloc_debug_enable (MALLOC_MCHECK_HOOK);

View File

@@ -167,10 +167,10 @@ get_mnt_entry (FILE *stream, struct mntent *mp, char *buffer, int bufsiz)
{ {
case 0: case 0:
mp->mnt_freq = 0; mp->mnt_freq = 0;
/* Fall through. */ [[fallthrough]] ;
case 1: case 1:
mp->mnt_passno = 0; mp->mnt_passno = 0;
/* Fall through. */ [[fallthrough]] ;
case 2: case 2:
break; break;
} }

View File

@@ -324,7 +324,7 @@ __do_niscall3 (dir_binding *dbp, u_long prog, xdrproc_t xargs, caddr_t req,
} }
/* Yes, the missing break is correct. If we doesn't have to /* Yes, the missing break is correct. If we doesn't have to
start a callback, look if we have to search another server */ start a callback, look if we have to search another server */
/* Fall through. */ [[fallthrough]] ;
case NIS_LOOKUP: case NIS_LOOKUP:
case NIS_ADD: case NIS_ADD:
case NIS_MODIFY: case NIS_MODIFY:

View File

@@ -68,7 +68,7 @@ ___pthread_mutex_trylock (pthread_mutex_t *mutex)
case PTHREAD_MUTEX_TIMED_NP: case PTHREAD_MUTEX_TIMED_NP:
FORCE_ELISION (mutex, goto elision); FORCE_ELISION (mutex, goto elision);
/*FALL THROUGH*/ [[fallthrough]] ;
case PTHREAD_MUTEX_ADAPTIVE_NP: case PTHREAD_MUTEX_ADAPTIVE_NP:
case PTHREAD_MUTEX_ERRORCHECK_NP: case PTHREAD_MUTEX_ERRORCHECK_NP:
if (lll_trylock (mutex->__data.__lock) != 0) if (lll_trylock (mutex->__data.__lock) != 0)

View File

@@ -319,7 +319,7 @@ __pthread_mutex_unlock_full (pthread_mutex_t *mutex, int decr)
if (mutex->__data.__owner != THREAD_GETMEM (THREAD_SELF, tid) if (mutex->__data.__owner != THREAD_GETMEM (THREAD_SELF, tid)
|| (mutex->__data.__lock & ~ PTHREAD_MUTEX_PRIO_CEILING_MASK) == 0) || (mutex->__data.__lock & ~ PTHREAD_MUTEX_PRIO_CEILING_MASK) == 0)
return EPERM; return EPERM;
/* FALLTHROUGH */ [[fallthrough]] ;
case PTHREAD_MUTEX_PP_NORMAL_NP: case PTHREAD_MUTEX_PP_NORMAL_NP:
case PTHREAD_MUTEX_PP_ADAPTIVE_NP: case PTHREAD_MUTEX_PP_ADAPTIVE_NP:

View File

@@ -230,7 +230,7 @@ __nss_hostname_digits_dots_context (struct resolv_context *ctx,
addr_size = IN6ADDRSZ; addr_size = IN6ADDRSZ;
break; break;
} }
/* FALLTHROUGH */ [[fallthrough]] ;
case AF_INET: case AF_INET:
/* This is not possible. We cannot represent an IPv6 address /* This is not possible. We cannot represent an IPv6 address

View File

@@ -52,13 +52,13 @@ __nss_hash (const void *keyarg, size_t len)
case 0: case 0:
/* h starts out as zero so no need to include the multiply. */ /* h starts out as zero so no need to include the multiply. */
h = *key++; h = *key++;
/* FALLTHROUGH */ [[fallthrough]];
case 3: case 3:
HASHC; HASHC;
/* FALLTHROUGH */ [[fallthrough]];
case 2: case 2:
HASHC; HASHC;
/* FALLTHROUGH */ [[fallthrough]];
case 1: case 1:
HASHC; HASHC;
/* FALLTHROUGH */ /* FALLTHROUGH */

View File

@@ -149,6 +149,7 @@ __execvpe_common (const char *file, char *const argv[], char *const envp[],
up finding no executable we can use, we want to diagnose up finding no executable we can use, we want to diagnose
that we did find one but were denied access. */ that we did find one but were denied access. */
got_eacces = true; got_eacces = true;
[[fallthrough]] ;
case ENOENT: case ENOENT:
case ESTALE: case ESTALE:
case ENOTDIR: case ENOTDIR:

View File

@@ -61,7 +61,7 @@ extern int fnmatch (const char *pattern, const char *string, int flags);
#endif #endif
#ifdef _LIBC #ifdef _LIBC
# if __GNUC__ >= 7 # if (__GNUC__ >= 7) || (__clang_major__ >= 10)
# define FALLTHROUGH __attribute__ ((__fallthrough__)) # define FALLTHROUGH __attribute__ ((__fallthrough__))
# else # else
# define FALLTHROUGH ((void) 0) # define FALLTHROUGH ((void) 0)

View File

@@ -834,7 +834,7 @@ re_string_elem_size_at (const re_string_t *pstr, Idx idx)
#endif /* RE_ENABLE_I18N */ #endif /* RE_ENABLE_I18N */
#ifdef _LIBC #ifdef _LIBC
# if __GNUC__ >= 7 # if (__GNUC__ >= 7) || (__clang_major__ >= 10)
# define FALLTHROUGH __attribute__ ((__fallthrough__)) # define FALLTHROUGH __attribute__ ((__fallthrough__))
# else # else
# define FALLTHROUGH ((void) 0) # define FALLTHROUGH ((void) 0)

View File

@@ -783,7 +783,7 @@ parse_arith (char **word, size_t *word_length, size_t *max_length,
case '(': case '(':
++paren_depth; ++paren_depth;
/* Fall through. */ [[fallthrough]] ;
default: default:
expr = w_addchar (expr, &expr_length, &expr_maxlen, words[*offset]); expr = w_addchar (expr, &expr_length, &expr_maxlen, words[*offset]);
if (expr == NULL) if (expr == NULL)
@@ -2103,7 +2103,7 @@ parse_backtick (char **word, size_t *word_length, size_t *max_length,
case '\'': case '\'':
squoting = 1 - squoting; squoting = 1 - squoting;
/* Fall through. */ [[fallthrough]] ;
default: default:
comm = w_addchar (comm, &comm_length, &comm_maxlen, words[*offset]); comm = w_addchar (comm, &comm_length, &comm_maxlen, words[*offset]);
if (comm == NULL) if (comm == NULL)

View File

@@ -275,7 +275,7 @@ b64_pton (char const *src, u_char *target, size_t targsize)
return (-1); return (-1);
ch = *src++; /* Skip the = */ ch = *src++; /* Skip the = */
/* Fall through to "single trailing =" case. */ /* Fall through to "single trailing =" case. */
/* FALLTHROUGH */ [[fallthrough]] ;
case 3: /* Valid, means two bytes of info */ case 3: /* Valid, means two bytes of info */
/* /*

View File

@@ -113,13 +113,13 @@ ns_parse_ttl(const char *src, u_long *dst) {
ch = toupper(ch); ch = toupper(ch);
switch (ch) { switch (ch) {
case 'W': tmp *= 7; case 'W': tmp *= 7;
/* Fall through. */ [[fallthrough]] ;
case 'D': tmp *= 24; case 'D': tmp *= 24;
/* Fall through. */ [[fallthrough]] ;
case 'H': tmp *= 60; case 'H': tmp *= 60;
/* Fall through. */ [[fallthrough]] ;
case 'M': tmp *= 60; case 'M': tmp *= 60;
/* Fall through. */ [[fallthrough]] ;
case 'S': break; case 'S': break;
default: goto einval; default: goto einval;
} }

View File

@@ -235,7 +235,7 @@ gethostbyname3_context (struct resolv_context *ctx,
case EMFILE: case EMFILE:
case ENFILE: case ENFILE:
h_errno = NETDB_INTERNAL; h_errno = NETDB_INTERNAL;
/* Fall through. */ [[fallthrough]] ;
case ECONNREFUSED: case ECONNREFUSED:
case ETIMEDOUT: case ETIMEDOUT:
status = NSS_STATUS_UNAVAIL; status = NSS_STATUS_UNAVAIL;
@@ -444,7 +444,7 @@ _nss_dns_gethostbyname4_r (const char *name, struct gaih_addrtuple **pat,
case EMFILE: case EMFILE:
case ENFILE: case ENFILE:
h_errno = NETDB_INTERNAL; h_errno = NETDB_INTERNAL;
/* Fall through. */ [[fallthrough]] ;
case ECONNREFUSED: case ECONNREFUSED:
case ETIMEDOUT: case ETIMEDOUT:
status = NSS_STATUS_UNAVAIL; status = NSS_STATUS_UNAVAIL;

View File

@@ -146,6 +146,7 @@ arg_trimdomain_list (const char *fname, int line_num, const char *args)
free (buf); free (buf);
return NULL; return NULL;
} }
[[fallthrough]] ;
default: default:
break; break;
} }

View File

@@ -277,7 +277,7 @@ __res_context_query (struct resolv_context *ctx, const char *name,
|| (hp2->rcode == NOERROR || (hp2->rcode == NOERROR
&& ntohs (hp2->ancount) != 0)) && ntohs (hp2->ancount) != 0))
goto success; goto success;
/* FALLTHROUGH */ [[fallthrough]] ;
case REFUSED: case REFUSED:
default: default:
RES_SET_H_ERRNO(statp, NO_RECOVERY); RES_SET_H_ERRNO(statp, NO_RECOVERY);
@@ -477,7 +477,7 @@ __res_context_search (struct resolv_context *ctx,
switch (statp->res_h_errno) { switch (statp->res_h_errno) {
case NO_DATA: case NO_DATA:
got_nodata++; got_nodata++;
/* FALLTHROUGH */ [[fallthrough]] ;
case HOST_NOT_FOUND: case HOST_NOT_FOUND:
/* keep trying */ /* keep trying */
break; break;
@@ -487,7 +487,7 @@ __res_context_search (struct resolv_context *ctx,
got_servfail++; got_servfail++;
break; break;
} }
/* FALLTHROUGH */ [[fallthrough]] ;
default: default:
/* anything else implies that we're done */ /* anything else implies that we're done */
done++; done++;

View File

@@ -272,7 +272,7 @@ __parse_one_specmb (const UCHAR_T *format, size_t posn,
if (*format != L_('l')) if (*format != L_('l'))
break; break;
++format; ++format;
/* FALLTHROUGH */ [[fallthrough]] ;
case L_('L'): case L_('L'):
/* doubles are long doubles, and ints are long long ints. */ /* doubles are long doubles, and ints are long long ints. */
case L_('q'): case L_('q'):

View File

@@ -915,7 +915,7 @@ __vfscanf_internal (FILE *s, const char *format, va_list argptr,
break; break;
} }
/* FALLTHROUGH */ [[fallthrough]];
case L_('C'): case L_('C'):
if (width == -1) if (width == -1)
width = 1; width = 1;
@@ -1258,7 +1258,7 @@ __vfscanf_internal (FILE *s, const char *format, va_list argptr,
} }
break; break;
} }
/* FALLTHROUGH */ [[fallthrough]] ;
case L_('S'): case L_('S'):
{ {

View File

@@ -334,7 +334,7 @@ readtcp (char *xprtptr, char *buf, int len)
case -1: case -1:
if (errno == EINTR) if (errno == EINTR)
continue; continue;
/*FALLTHROUGH*/ [[fallthrough]];
case 0: case 0:
goto fatal_err; goto fatal_err;
default: default:

View File

@@ -440,7 +440,7 @@ readunix (char *xprtptr, char *buf, int len)
case -1: case -1:
if (errno == EINTR) if (errno == EINTR)
continue; continue;
/*FALLTHROUGH*/ [[fallthrough]] ;
case 0: case 0:
goto fatal_err; goto fatal_err;
default: default:

View File

@@ -113,7 +113,7 @@ xdr_int (XDR *xdrs, int *ip)
return FALSE; return FALSE;
} }
*ip = (int) l; *ip = (int) l;
/* Fall through. */ [[fallthrough]] ;
case XDR_FREE: case XDR_FREE:
return TRUE; return TRUE;
} }
@@ -153,7 +153,7 @@ xdr_u_int (XDR *xdrs, u_int *up)
return FALSE; return FALSE;
} }
*up = (u_int) (u_long) l; *up = (u_int) (u_long) l;
/* Fall through. */ [[fallthrough]] ;
case XDR_FREE: case XDR_FREE:
return TRUE; return TRUE;
} }
@@ -508,7 +508,7 @@ xdr_enum (XDR *xdrs, enum_t *ep)
return FALSE; return FALSE;
} }
*ep = l; *ep = l;
/* Fall through. */ [[fallthrough]] ;
case XDR_FREE: case XDR_FREE:
return TRUE; return TRUE;
@@ -631,7 +631,7 @@ xdr_bytes (XDR *xdrs, char **cpp, u_int *sizep, u_int maxsize)
(void) __fxprintf (NULL, "%s: %s", __func__, _("out of memory\n")); (void) __fxprintf (NULL, "%s: %s", __func__, _("out of memory\n"));
return FALSE; return FALSE;
} }
/* Fall through. */ [[fallthrough]] ;
case XDR_ENCODE: case XDR_ENCODE:
return xdr_opaque (xdrs, sp, nodesize); return xdr_opaque (xdrs, sp, nodesize);
@@ -752,7 +752,7 @@ xdr_string (XDR *xdrs, char **cpp, u_int maxsize)
{ {
return TRUE; /* already free */ return TRUE; /* already free */
} }
/* fall through... */ [[fallthrough]] ;
case XDR_ENCODE: case XDR_ENCODE:
if (sp == NULL) if (sp == NULL)
return FALSE; return FALSE;
@@ -792,7 +792,7 @@ xdr_string (XDR *xdrs, char **cpp, u_int maxsize)
return FALSE; return FALSE;
} }
sp[size] = 0; sp[size] = 0;
/* Fall through. */ [[fallthrough]] ;
case XDR_ENCODE: case XDR_ENCODE:
return xdr_opaque (xdrs, sp, size); return xdr_opaque (xdrs, sp, size);

View File

@@ -20,6 +20,7 @@
#define _AARCH64_FPU_CONTROL_H #define _AARCH64_FPU_CONTROL_H
#include <features.h> #include <features.h>
#include <sys/types.h>
/* Macros for accessing the FPCR and FPSR. */ /* Macros for accessing the FPCR and FPSR. */

View File

@@ -402,12 +402,16 @@ __ieee754_lgammal_r (long double x, int *signgamp)
{ {
case 7: case 7:
z *= (y + 6.0); /* FALLTHRU */ z *= (y + 6.0); /* FALLTHRU */
[[fallthrough]] ;
case 6: case 6:
z *= (y + 5.0); /* FALLTHRU */ z *= (y + 5.0); /* FALLTHRU */
[[fallthrough]] ;
case 5: case 5:
z *= (y + 4.0); /* FALLTHRU */ z *= (y + 4.0); /* FALLTHRU */
[[fallthrough]] ;
case 4: case 4:
z *= (y + 3.0); /* FALLTHRU */ z *= (y + 3.0); /* FALLTHRU */
[[fallthrough]] ;
case 3: case 3:
z *= (y + 2.0); /* FALLTHRU */ z *= (y + 2.0); /* FALLTHRU */
r += __ieee754_logl (z); r += __ieee754_logl (z);

View File

@@ -798,7 +798,7 @@ init_cpu_features (struct cpu_features *cpu_features)
processor. */ processor. */
if (stepping > 0xc) if (stepping > 0xc)
break; break;
/* Fall through. */ [[fallthrough]] ;
case INTEL_BIGCORE_SKYLAKE: case INTEL_BIGCORE_SKYLAKE:
/* Disable Intel TSX and enable RTM_ALWAYS_ABORT for /* Disable Intel TSX and enable RTM_ALWAYS_ABORT for
processors listed in: processors listed in:
@@ -937,7 +937,7 @@ disable_tsx:
non-temporal on all Skylake servers. */ non-temporal on all Skylake servers. */
cpu_features->preferred[index_arch_Avoid_Non_Temporal_Memset] cpu_features->preferred[index_arch_Avoid_Non_Temporal_Memset]
|= bit_arch_Avoid_Non_Temporal_Memset; |= bit_arch_Avoid_Non_Temporal_Memset;
/* fallthrough */ [[fallthrough]] ;
case INTEL_BIGCORE_COMETLAKE: case INTEL_BIGCORE_COMETLAKE:
case INTEL_BIGCORE_SKYLAKE: case INTEL_BIGCORE_SKYLAKE:
case INTEL_BIGCORE_KABYLAKE: case INTEL_BIGCORE_KABYLAKE:
@@ -1091,7 +1091,7 @@ disable_tsx:
/* Yongfeng and Shijidadao mircoarch tuning. */ /* Yongfeng and Shijidadao mircoarch tuning. */
case 0x5b: case 0x5b:
cpu_features->cachesize_non_temporal_divisor = 2; cpu_features->cachesize_non_temporal_divisor = 2;
/* fallthrough */ [[fallthrough]] ;
case 0x6b: case 0x6b:
cpu_features->preferred[index_arch_AVX_Fast_Unaligned_Load] cpu_features->preferred[index_arch_AVX_Fast_Unaligned_Load]
&= ~bit_arch_AVX_Fast_Unaligned_Load; &= ~bit_arch_AVX_Fast_Unaligned_Load;

View File

@@ -44,7 +44,7 @@ process_elf_file (const char *file_name, const char *lib, int *flag,
case EM_386: case EM_386:
if (elf_header->e_ident[EI_CLASS] == ELFCLASS32) if (elf_header->e_ident[EI_CLASS] == ELFCLASS32)
break; break;
/* Fall through. */ [[fallthrough]] ;
default: default:
error (0, 0, _("%s is for unknown machine %d.\n"), error (0, 0, _("%s is for unknown machine %d.\n"),
file_name, elf_header->e_machine); file_name, elf_header->e_machine);

View File

@@ -313,7 +313,7 @@ and creates an unsatisfiable circular dependency.\n",
{ {
case R_X86_64_JUMP_SLOT: case R_X86_64_JUMP_SLOT:
map->l_has_jump_slot_reloc = true; map->l_has_jump_slot_reloc = true;
/* fallthrough */ [[fallthrough]];
case R_X86_64_GLOB_DAT: case R_X86_64_GLOB_DAT:
*reloc_addr = value; *reloc_addr = value;
break; break;
@@ -422,7 +422,7 @@ and creates an unsatisfiable circular dependency.\n",
/* Set to symbol size plus addend. */ /* Set to symbol size plus addend. */
value = sym->st_size; value = sym->st_size;
# endif # endif
/* Fall through. */ [[fallthrough]];
case R_X86_64_32: case R_X86_64_32:
value += reloc->r_addend; value += reloc->r_addend;
*(unsigned int *) reloc_addr = value; *(unsigned int *) reloc_addr = value;

View File

@@ -1093,7 +1093,7 @@ __strftime_internal (CHAR_T *s, size_t maxsize, const CHAR_T *format,
#if !defined _NL_CURRENT && HAVE_STRFTIME #if !defined _NL_CURRENT && HAVE_STRFTIME
format_char = L_('p'); format_char = L_('p');
#endif #endif
/* FALLTHROUGH */ [[fallthrough]] ;
case L_('p'): case L_('p'):
if (change_case) if (change_case)
@@ -1433,7 +1433,7 @@ __strftime_internal (CHAR_T *s, size_t maxsize, const CHAR_T *format,
case L_('\0'): /* GNU extension: % at end of format. */ case L_('\0'): /* GNU extension: % at end of format. */
--f; --f;
/* Fall through. */ [[fallthrough]] ;
default: default:
/* Unknown format; output the format, including the '%', /* Unknown format; output the format, including the '%',
since this is most likely the right thing to do if a since this is most likely the right thing to do if a

View File

@@ -552,7 +552,7 @@ __strptime_internal (const char *rp, const char *fmt, struct tm *tmp,
s.decided = raw; s.decided = raw;
} }
#endif #endif
/* Fall through. */ [[fallthrough]] ;
case 'D': case 'D':
/* Match standard day format. */ /* Match standard day format. */
if (!recursive (HERE_D_FMT)) if (!recursive (HERE_D_FMT))
@@ -706,7 +706,7 @@ __strptime_internal (const char *rp, const char *fmt, struct tm *tmp,
s.decided = raw; s.decided = raw;
} }
#endif #endif
/* Fall through. */ [[fallthrough]] ;
case 'T': case 'T':
if (!recursive (HERE_T_FMT)) if (!recursive (HERE_T_FMT))
return NULL; return NULL;