[libcxx-commits] [libcxxabi] 8be4bd8 - [libcxxabi] Fix the long double demangling for PowerPC (#135332)
via libcxx-commits
libcxx-commits at lists.llvm.org
Fri Apr 11 02:24:17 PDT 2025
Author: Martin Storsjö
Date: 2025-04-11T12:24:13+03:00
New Revision: 8be4bd85708cddc8d84d03cf77ba4b02d0b6d44c
URL: https://github.com/llvm/llvm-project/commit/8be4bd85708cddc8d84d03cf77ba4b02d0b6d44c
DIFF: https://github.com/llvm/llvm-project/commit/8be4bd85708cddc8d84d03cf77ba4b02d0b6d44c.diff
LOG: [libcxxabi] Fix the long double demangling for PowerPC (#135332)
PowerPC uses a slightly different type of floats for their 128 bit long
doubles, as "double-double", with __LDBL_MANT_DIG__ == 106 rather than
__LDBL_MANT_DIG__ == 113 for IEEE 128 bit floats.
This fixes compiling libcxxabi for PowerPC after
3b70715c13876c51542ebfe2e3f4ee908f6785cb.
Added:
Modified:
libcxxabi/src/demangle/ItaniumDemangle.h
Removed:
################################################################################
diff --git a/libcxxabi/src/demangle/ItaniumDemangle.h b/libcxxabi/src/demangle/ItaniumDemangle.h
index b9d17060c04f9..eca9ddad66f92 100644
--- a/libcxxabi/src/demangle/ItaniumDemangle.h
+++ b/libcxxabi/src/demangle/ItaniumDemangle.h
@@ -5741,7 +5741,7 @@ struct FloatData<double>
template <>
struct FloatData<long double>
{
-#if __LDBL_MANT_DIG__ == 113
+#if __LDBL_MANT_DIG__ == 113 || __LDBL_MANT_DIG__ == 106
static const size_t mangled_size = 32;
#elif __LDBL_MANT_DIG__ == 53 || defined(_MSC_VER)
// MSVC doesn't define __LDBL_MANT_DIG__, but it has long double equal to
More information about the libcxx-commits
mailing list