
12 Jul
2024
12 Jul
'24
6:54 p.m.
On Fri, Jul 12, 2024 at 01:26:35PM +0200, Richard Weinberger wrote:
Am Freitag, 12. Juli 2024, 13:19:32 CEST schrieb Heinrich Schuchardt:
Hm, I see man built-ins in the U-Boot source. Why is this one special?
See the definition of COMPILER_HAS_GENERIC_BUILTIN_OVERFLOW in include/linux/compiler-clang.h.
So I can't use __builtin_add_overflow() because u-boot is still supporting outdated compilers that don't offer __builtin_add_overflow()?
Maybe this is the ideal moment to raise the bar? __builtin_add_overflow() is supported by gcc >= 5.1 and clang >= 8.
We already fail on gcc older than 6, for ARM. And we don't have a minimum clang specifically, but it's probably newer than 8. So this should be fine.
--
Tom