Index: common/lib/libc/misc/ubsan.c =================================================================== RCS file: /cvsroot/src/common/lib/libc/misc/ubsan.c,v retrieving revision 1.4 diff -u -r1.4 ubsan.c --- common/lib/libc/misc/ubsan.c 4 Feb 2019 22:07:41 -0000 1.4 +++ common/lib/libc/misc/ubsan.c 13 Feb 2019 17:05:41 -0000 @@ -110,7 +110,7 @@ #define NUMBER_SIGNED_BIT 1U -#if __SIZEOF_INT128__ +#ifdef __SIZEOF_INT128__ typedef __int128 longest; typedef unsigned __int128 ulongest; #else @@ -1192,6 +1192,7 @@ } if (isFatal || ISSET(ubsan_flags, UBSAN_ABORT)) { abort(); + __unreachable(); /* NOTREACHED */ } #endif @@ -1291,6 +1292,7 @@ switch (zDeserializeTypeWidth(pType)) { default: ASSERT(0 && "Invalid codepath"); + __unreachable(); /* NOTREACHED */ #ifdef __SIZEOF_INT128__ case WIDTH_128: @@ -1298,8 +1300,11 @@ break; #endif case WIDTH_64: + /* FALLTHROUGH */ case WIDTH_32: + /* FALLTHROUGH */ case WIDTH_16: + /* FALLTHROUGH */ case WIDTH_8: snprintf(pBuffer, zBUfferLength, "%" PRId64, STATIC_CAST(int64_t, L)); break; @@ -1318,6 +1323,7 @@ switch (zDeserializeTypeWidth(pType)) { default: ASSERT(0 && "Invalid codepath"); + __unreachable(); /* NOTREACHED */ #ifdef __SIZEOF_INT128__ case WIDTH_128: @@ -1325,8 +1331,11 @@ break; #endif case WIDTH_64: + /* FALLTHROUGH */ case WIDTH_32: + /* FALLTHROUGH */ case WIDTH_16: + /* FALLTHROUGH */ case WIDTH_8: snprintf(pBuffer, zBUfferLength, "%" PRIu64, STATIC_CAST(uint64_t, L)); break; @@ -1358,7 +1367,9 @@ switch (zDeserializeTypeWidth(pType)) { #ifdef __HAVE_LONG_DOUBLE case WIDTH_128: + /* FALLTHROUGH */ case WIDTH_96: + /* FALLTHROUGH */ case WIDTH_80: memcpy(&LD, pNumber, sizeof(long double)); snprintf(pBuffer, zBUfferLength, "%Lg", LD); @@ -1512,7 +1523,9 @@ /* NOTREACHED */ #ifdef __HAVE_LONG_DOUBLE case WIDTH_128: + /* FALLTHROUGH */ case WIDTH_96: + /* FALLTHROUGH */ case WIDTH_80: DeserializeFloatOverPointer(pBuffer, zBUfferLength, pType, REINTERPRET_CAST(unsigned long *, ulNumber)); break; @@ -1524,6 +1537,7 @@ } /* FALLTHROUGH */ case WIDTH_32: + /* FALLTHROUGH */ case WIDTH_16: DeserializeFloatInlined(pBuffer, zBUfferLength, pType, ulNumber); break;