1287516Sdim//===-- lib/truncsfhf2.c - single -> half conversion --------------*- C -*-===// 2287516Sdim// 3287516Sdim// The LLVM Compiler Infrastructure 4287516Sdim// 5287516Sdim// This file is dual licensed under the MIT and the University of Illinois Open 6287516Sdim// Source Licenses. See LICENSE.TXT for details. 7287516Sdim// 8287516Sdim//===----------------------------------------------------------------------===// 9287516Sdim 10287516Sdim#define SRC_SINGLE 11287516Sdim#define DST_HALF 12287516Sdim#include "fp_trunc_impl.inc" 13287516Sdim 14296417SdimARM_EABI_FNALIAS(f2h, truncsfhf2) 15296417Sdim 16287516Sdim// Use a forwarding definition and noinline to implement a poor man's alias, 17287516Sdim// as there isn't a good cross-platform way of defining one. 18296417SdimCOMPILER_RT_ABI NOINLINE uint16_t __truncsfhf2(float a) { 19287516Sdim return __truncXfYf2__(a); 20287516Sdim} 21287516Sdim 22287516SdimCOMPILER_RT_ABI uint16_t __gnu_f2h_ieee(float a) { 23287516Sdim return __truncsfhf2(a); 24287516Sdim} 25