[clang] Handle __declspec() attributes in using
[llvm-project.git] / compiler-rt / lib / builtins / subdf3.c
blob2100fd39c4ef033b8477478c19b5eb0fcd4309fc
1 //===-- lib/adddf3.c - Double-precision subtraction ---------------*- C -*-===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
8 //
9 // This file implements double-precision soft-float subtraction.
11 //===----------------------------------------------------------------------===//
13 #define DOUBLE_PRECISION
14 #include "fp_lib.h"
16 // Subtraction; flip the sign bit of b and add.
17 COMPILER_RT_ABI fp_t __subdf3(fp_t a, fp_t b) {
18 return __adddf3(a, fromRep(toRep(b) ^ signBit));
21 #if defined(__ARM_EABI__)
22 #if defined(COMPILER_RT_ARMHF_TARGET)
23 AEABI_RTABI fp_t __aeabi_dsub(fp_t a, fp_t b) { return __subdf3(a, b); }
24 #else
25 COMPILER_RT_ALIAS(__subdf3, __aeabi_dsub)
26 #endif
27 #endif