Date: Tue, 24 Feb 2026 20:24:28 +0000 From: John Baldwin <jhb@FreeBSD.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: git: 5faceb84142f - main - __builtin_align_down: Cast value to __uintptr_t in the fallback Message-ID: <699e08fc.23d15.721aa131@gitrepo.freebsd.org>
index | next in thread | raw e-mail
The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=5faceb84142f3c9886f38a03dd5214785ac6961f commit 5faceb84142f3c9886f38a03dd5214785ac6961f Author: John Baldwin <jhb@FreeBSD.org> AuthorDate: 2026-02-24 20:24:17 +0000 Commit: John Baldwin <jhb@FreeBSD.org> CommitDate: 2026-02-24 20:24:17 +0000 __builtin_align_down: Cast value to __uintptr_t in the fallback This matches the behavior of the fallbacks for __builtin_align_up and __builtin_is_aligned. Reviewed by: arichardson, ngie, kib Differential Revision: https://reviews.freebsd.org/D55161 --- sys/sys/cdefs.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/sys/cdefs.h b/sys/sys/cdefs.h index ea6a92ad0056..132d4809b0ed 100644 --- a/sys/sys/cdefs.h +++ b/sys/sys/cdefs.h @@ -649,7 +649,7 @@ #endif #if !__has_builtin(__builtin_align_down) #define __builtin_align_down(x, align) \ - ((__typeof__(x))((x)&(~((align)-1)))) + ((__typeof__(x))((__uintptr_t)(x)&(~((align)-1)))) #endif #define __align_up(x, y) __builtin_align_up(x, y)home | help
Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?699e08fc.23d15.721aa131>
