From 52e7052b6cc61fa831cbfff8a815ad9bf3efcd18 Mon Sep 17 00:00:00 2001 From: Dave Rodgman Date: Tue, 31 Oct 2023 23:26:44 +0000 Subject: [PATCH] tidy up comments Signed-off-by: Dave Rodgman --- library/common.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/library/common.h b/library/common.h index 4f4c222fa6..3e81e81ea1 100644 --- a/library/common.h +++ b/library/common.h @@ -318,15 +318,15 @@ static inline void mbedtls_xor_no_simd(unsigned char *r, #define MBEDTLS_UNLIKELY(x) x #endif -#if defined(__has_builtin) -#if __has_builtin(__builtin_assume) /* MBEDTLS_ASSUME may be used to provide additional information to the compiler * which can result in smaller code-size. */ +#if defined(__has_builtin) +#if __has_builtin(__builtin_assume) +/* clang provides __builtin_assume */ #define MBEDTLS_ASSUME(x) __builtin_assume(x) -// clang provides __builtin_assume #elif __has_builtin(__builtin_unreachable) +/* gcc can use __builtin_unreachable */ #define MBEDTLS_ASSUME(x) do { if (!(x)) __builtin_unreachable(); } while (0) -// For gcc, use __builtin_unreachable #endif #endif #if !defined(MBEDTLS_ASSUME)