[PATCH] longlong.h: loongarch64: replace unsigned __int128__ with __uint128_t

Yao Zi ziyao at disroot.org
Sat Nov 23 16:07:31 CET 2024


# HG changeset patch
# User Yao Zi <ziyao at disroot.org>
# Date 1732371310 -28800
#      Sat Nov 23 22:15:10 2024 +0800
# Node ID e2b6d6999ac46ca8e1296343a9a7c7e2293664ff
# Parent  6df5dd697f5a547d8ac172efbace161914e23f78
longlong.h: loongarch64: replace unsigned __int128__ with __uint128_t

Both as compiler extensions, __uint128_t is supported more widely than
unsigned __int128__. This change enables gmp to build with Clang 19.

diff -r 6df5dd697f5a -r e2b6d6999ac4 longlong.h
--- a/longlong.h	Fri Oct 18 19:16:58 2024 +0200
+++ b/longlong.h	Sat Nov 23 22:15:10 2024 +0800
@@ -1162,7 +1162,7 @@
   do {									\
     UDItype __u = (u), __v = (v);					\
     (w0) = __u * __v;							\
-    (w1) = (unsigned __int128__) __u * __v >> 64;			\
+    (w1) = (__uint128_t) __u * __v >> 64;			\
   } while (0)
 #endif
 




More information about the gmp-devel mailing list