1*b66aa3bfSOverMighty //===-- Performance test for expf16 ---------------------------------------===// 2971a1ac4SOverMighty // 3971a1ac4SOverMighty // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. 4971a1ac4SOverMighty // See https://llvm.org/LICENSE.txt for license information. 5971a1ac4SOverMighty // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception 6971a1ac4SOverMighty // 7971a1ac4SOverMighty //===----------------------------------------------------------------------===// 8971a1ac4SOverMighty 9971a1ac4SOverMighty #include "SingleInputSingleOutputPerf.h" 10971a1ac4SOverMighty 11971a1ac4SOverMighty #include "src/math/expf16.h" 12971a1ac4SOverMighty 13971a1ac4SOverMighty // LLVM libc might be the only libc implementation with support for float16 math 14971a1ac4SOverMighty // functions currently. We can't compare our float16 functions against the 15971a1ac4SOverMighty // system libc, so we compare them against this placeholder function. 16971a1ac4SOverMighty static float16 placeholderf16(float16 x) { return x; } 17971a1ac4SOverMighty 18971a1ac4SOverMighty int main() { 19971a1ac4SOverMighty SINGLE_INPUT_SINGLE_OUTPUT_PERF_EX(float16, LIBC_NAMESPACE::expf16, 20971a1ac4SOverMighty ::placeholderf16, 20'000, 21971a1ac4SOverMighty "expf16_perf.log") 22971a1ac4SOverMighty } 23