]> granicus.if.org Git - clang/commit
Implement __builtin_signbitl for PowerPC
authorHal Finkel <hfinkel@anl.gov>
Sun, 24 Aug 2014 03:47:06 +0000 (03:47 +0000)
committerHal Finkel <hfinkel@anl.gov>
Sun, 24 Aug 2014 03:47:06 +0000 (03:47 +0000)
commit041b099ee1e18ca85b0b07d66d3488092c1f4b91
tree8a1e0ea303fb5144228ad476c388d60fb7b562fa
parent852eed5f0c761aa46f4e8dffb0432f81ab1dc9fa
Implement __builtin_signbitl for PowerPC

PowerPC uses the special PPC_FP128 type for long double on Linux, which is
composed of two 64-bit doubles. The higher-order double (which contains the
overall sign) comes first, and so the __builtin_signbitl implementation
requires special handling to extract the sign bit.

Fixes PR20691.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@216341 91177308-0d34-0410-b5e6-96231b3b80d8
lib/CodeGen/CGBuiltin.cpp
test/CodeGen/ppc-signbit.c [new file with mode: 0644]