Eric Fiselier | 2a58b11 | 2018-12-17 20:17:43 +0000 | [diff] [blame] | 1 | //===----------------------------------------------------------------------===// |
| 2 | // |
Chandler Carruth | 57b08b0 | 2019-01-19 10:56:40 +0000 | [diff] [blame^] | 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 |
Eric Fiselier | 2a58b11 | 2018-12-17 20:17:43 +0000 | [diff] [blame] | 6 | // |
| 7 | //===----------------------------------------------------------------------===// |
| 8 | |
| 9 | inline long double truncate_fp(long double val) { |
| 10 | volatile long double sink = val; |
| 11 | return sink; |
| 12 | } |
| 13 | |
| 14 | inline double truncate_fp(double val) { |
| 15 | volatile double sink = val; |
| 16 | return sink; |
| 17 | } |
| 18 | |
| 19 | inline float truncate_fp(float val) { |
| 20 | volatile float sink = val; |
| 21 | return sink; |
| 22 | } |