16b5ae148SOverMighty //===-- Implementation of fromfpf16 function ------------------------------===// 26b5ae148SOverMighty // 36b5ae148SOverMighty // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. 46b5ae148SOverMighty // See https://llvm.org/LICENSE.txt for license information. 56b5ae148SOverMighty // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception 66b5ae148SOverMighty // 76b5ae148SOverMighty //===----------------------------------------------------------------------===// 86b5ae148SOverMighty 96b5ae148SOverMighty #include "src/math/fromfpf16.h" 106b5ae148SOverMighty #include "src/__support/FPUtil/NearestIntegerOperations.h" 116b5ae148SOverMighty #include "src/__support/common.h" 12*5ff3ff33SPetr Hosek #include "src/__support/macros/config.h" 136b5ae148SOverMighty 14*5ff3ff33SPetr Hosek namespace LIBC_NAMESPACE_DECL { 156b5ae148SOverMighty 166b5ae148SOverMighty LLVM_LIBC_FUNCTION(float16, fromfpf16, 176b5ae148SOverMighty (float16 x, int rnd, unsigned int width)) { 186b5ae148SOverMighty return fputil::fromfp</*IsSigned=*/true>(x, rnd, width); 196b5ae148SOverMighty } 206b5ae148SOverMighty 21*5ff3ff33SPetr Hosek } // namespace LIBC_NAMESPACE_DECL 22