[libc++] hash<long double>: adjust for x86-64 ILP32

x86-64 ILP32 mode (x32) uses 32-bit size_t, so share the code with ix86 to zero out padding bits, not with x86-64 LP64 mode.

Reviewed By: #libc, ldionne

Differential Revision: https://reviews.llvm.org/D91349
This commit is contained in:
Harald van Dijk
2020-11-29 13:52:28 +00:00
parent d99da80841
commit fba0b65f72

View File

@@ -1506,7 +1506,7 @@ struct _LIBCPP_TEMPLATE_VIS hash<long double>
// -0.0 and 0.0 should return same hash
if (__v == 0.0L)
return 0;
#if defined(__i386__)
#if defined(__i386__) || (defined(__x86_64__) && defined(__ILP32__))
// Zero out padding bits
union
{