[PATCH] D86668: Fix Calling Convention of __float128 and long double(128bits) in i386
John McCall via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Aug 27 01:12:00 PDT 2020
rjmccall added inline comments.
================
Comment at: clang/lib/CodeGen/TargetInfo.cpp:1603
+ if (IsLinuxABI && Ty->isFloatingType() && getContext().getTypeSize(Ty) == 128)
+ return 16;
+
----------------
I don't think this should be restricted to just Linux. It's a fix for all OSes that support `__float128`, i.e. Haiku, Linux, OpenBSD, and Solaris.
It would be better to check the floating-point semantics rather than relying on the type size, since the type size could easily be rounded up to 128 for alignment reasons.
Should this also apply to structs containing `__float128`, the same way that SIMD does below?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D86668/new/
https://reviews.llvm.org/D86668
More information about the cfe-commits
mailing list