blob: 862d7bd6c7af5c30dfb51725e6a1b7537a648223 [file] [log] [blame]
Edward O'Callaghan4856eef2009-08-05 04:02:56 +00001/* ===-- fixunssfti.c - Implement __fixunssfti -----------------------------===
2 *
3 * The LLVM Compiler Infrastructure
4 *
Howard Hinnant5b791f62010-11-16 22:13:33 +00005 * This file is dual licensed under the MIT and the University of Illinois Open
6 * Source Licenses. See LICENSE.TXT for details.
Edward O'Callaghan4856eef2009-08-05 04:02:56 +00007 *
8 * ===----------------------------------------------------------------------===
9 *
10 * This file implements __fixunssfti for the compiler_rt library.
11 *
12 * ===----------------------------------------------------------------------===
13 */
Daniel Dunbarfd089992009-06-26 16:47:03 +000014
Joerg Sonnenberger1aa3faa2015-03-13 00:18:28 +000015#define SINGLE_PRECISION
16#include "fp_lib.h"
17
Joerg Sonnenberger91bd6982015-03-11 21:13:56 +000018#if defined(CRT_HAS_128BIT)
19typedef tu_int fixuint_t;
20#include "fp_fixuint_impl.inc"
Daniel Dunbarfd089992009-06-26 16:47:03 +000021
Joerg Sonnenberger6e99daa2014-03-01 15:30:50 +000022COMPILER_RT_ABI tu_int
Joerg Sonnenberger91bd6982015-03-11 21:13:56 +000023__fixunssfti(fp_t a) {
24 return __fixuint(a);
Daniel Dunbarfd089992009-06-26 16:47:03 +000025}
Joerg Sonnenberger91bd6982015-03-11 21:13:56 +000026#endif