Re: git: b88ca6ee167d - main - cdefs: Remove CC_SUPPORTS macros, they are unused
Date: Mon, 27 Nov 2023 17:50:14 UTC
On 11/26/23 9:25 PM, Warner Losh wrote:
> The branch main has been updated by imp:
>
> URL: https://cgit.FreeBSD.org/src/commit/?id=b88ca6ee167d079c965dfe123bbe296d3a945c0a
>
> commit b88ca6ee167d079c965dfe123bbe296d3a945c0a
> Author: Warner Losh <imp@FreeBSD.org>
> AuthorDate: 2023-11-20 22:40:55 +0000
> Commit: Warner Losh <imp@FreeBSD.org>
> CommitDate: 2023-11-27 05:24:02 +0000
>
> cdefs: Remove CC_SUPPORTS macros, they are unused
>
> Remove __CC_SUPPORTS_INLINE, __CC_SUPPORTS___INLINE__,
> __CC_SUPPORTS___FUNC__, __CC_SUPPORTS_WARNING,
> __CC_SUPPORTS_VARADIC_XXX, __CC_SUPPORTS_DYNAMIC_ARRAY_INIT: they are
> unused. Also remove them from the generated cryptodevh.py script.
>
> Retain, for the moment, __CC_SUPPORTS___INLINE, since it's used in this
> file.
>
> PR: 275221 (exp-run)
> Sponsored by: Netflix
> ---
> sys/sys/cdefs.h | 10 ----------
> tests/sys/opencrypto/cryptodevh.py | 7 -------
> 2 files changed, 17 deletions(-)
>
> diff --git a/sys/sys/cdefs.h b/sys/sys/cdefs.h
> index 5782735187c5..7f3efc9300c9 100644
> --- a/sys/sys/cdefs.h
> +++ b/sys/sys/cdefs.h
> @@ -79,17 +79,7 @@
> */
> #define __compiler_membar() __asm __volatile(" " : : : "memory")
>
> -/* XXX: if __GNUC__ >= 2: not tested everywhere originally, where replaced */
> -#define __CC_SUPPORTS_INLINE 1
> #define __CC_SUPPORTS___INLINE 1
> -#define __CC_SUPPORTS___INLINE__ 1
> -
> -#define __CC_SUPPORTS___FUNC__ 1
> -#define __CC_SUPPORTS_WARNING 1
> -
> -#define __CC_SUPPORTS_VARADIC_XXX 1 /* see varargs.h */
> -
> -#define __CC_SUPPORTS_DYNAMIC_ARRAY_INIT 1
>
> #endif /* __GNUC__ */
>
> diff --git a/tests/sys/opencrypto/cryptodevh.py b/tests/sys/opencrypto/cryptodevh.py
> index d6982c26f1cf..9607bcd4d115 100644
> --- a/tests/sys/opencrypto/cryptodevh.py
> +++ b/tests/sys/opencrypto/cryptodevh.py
> @@ -23,13 +23,6 @@ def __has_include(x): return 0
>
> def __has_builtin(x): return 0
>
> -__CC_SUPPORTS_INLINE = 1
> -__CC_SUPPORTS___INLINE = 1
> -__CC_SUPPORTS___INLINE__ = 1
> -__CC_SUPPORTS___FUNC__ = 1
> -__CC_SUPPORTS_WARNING = 1
> -__CC_SUPPORTS_VARADIC_XXX = 1
> -__CC_SUPPORTS_DYNAMIC_ARRAY_INIT = 1
> def __P(protos): return protos
>
> def __STRING(x): return #x
It doesn't really matter, but you accidentally removed __CC_SUPPORTS___INLINE from
the python version but not cdefs.h. I wonder how hard it would be to just regenerate
cryptodevh.py rather than updating it manually as I'm sure it is missing some other
updates.
--
John Baldwin