1//===-- VecFuncs.def - Library information -------------*- C++ -*-----------===// 2// 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 6// 7//===----------------------------------------------------------------------===// 8 9// This .def file will create mappings from scalar math functions to vector 10// functions along with their vectorization factor. The current support includes 11// such mappings for Accelerate framework, MASS vector library, and SVML library. 12// This .def file also allows creating an array of vector functions supported in 13// the specified framework or library. 14 15#if defined(TLI_DEFINE_MASSV_VECFUNCS_NAMES) 16#define TLI_DEFINE_MASSV_VECFUNCS 17#define TLI_DEFINE_VECFUNC(SCAL, VEC, VF) VEC, 18#endif 19 20#define FIXED(NL) ElementCount::getFixed(NL) 21#define SCALABLE(NL) ElementCount::getScalable(NL) 22 23#if !(defined(TLI_DEFINE_VECFUNC)) 24#define TLI_DEFINE_VECFUNC(SCAL, VEC, VF) {SCAL, VEC, VF}, 25#endif 26 27#if defined(TLI_DEFINE_ACCELERATE_VECFUNCS) 28// Accelerate framework's Vector Functions 29 30// Floating-Point Arithmetic and Auxiliary Functions 31TLI_DEFINE_VECFUNC("ceilf", "vceilf", FIXED(4)) 32TLI_DEFINE_VECFUNC("fabsf", "vfabsf", FIXED(4)) 33TLI_DEFINE_VECFUNC("llvm.fabs.f32", "vfabsf", FIXED(4)) 34TLI_DEFINE_VECFUNC("floorf", "vfloorf", FIXED(4)) 35TLI_DEFINE_VECFUNC("sqrtf", "vsqrtf", FIXED(4)) 36TLI_DEFINE_VECFUNC("llvm.sqrt.f32", "vsqrtf", FIXED(4)) 37 38// Exponential and Logarithmic Functions 39TLI_DEFINE_VECFUNC("expf", "vexpf", FIXED(4)) 40TLI_DEFINE_VECFUNC("llvm.exp.f32", "vexpf", FIXED(4)) 41TLI_DEFINE_VECFUNC("expm1f", "vexpm1f", FIXED(4)) 42TLI_DEFINE_VECFUNC("logf", "vlogf", FIXED(4)) 43TLI_DEFINE_VECFUNC("llvm.log.f32", "vlogf", FIXED(4)) 44TLI_DEFINE_VECFUNC("log1pf", "vlog1pf", FIXED(4)) 45TLI_DEFINE_VECFUNC("log10f", "vlog10f", FIXED(4)) 46TLI_DEFINE_VECFUNC("llvm.log10.f32", "vlog10f", FIXED(4)) 47TLI_DEFINE_VECFUNC("logbf", "vlogbf", FIXED(4)) 48 49// Trigonometric Functions 50TLI_DEFINE_VECFUNC("sinf", "vsinf", FIXED(4)) 51TLI_DEFINE_VECFUNC("llvm.sin.f32", "vsinf", FIXED(4)) 52TLI_DEFINE_VECFUNC("cosf", "vcosf", FIXED(4)) 53TLI_DEFINE_VECFUNC("llvm.cos.f32", "vcosf", FIXED(4)) 54TLI_DEFINE_VECFUNC("tanf", "vtanf", FIXED(4)) 55TLI_DEFINE_VECFUNC("asinf", "vasinf", FIXED(4)) 56TLI_DEFINE_VECFUNC("acosf", "vacosf", FIXED(4)) 57TLI_DEFINE_VECFUNC("atanf", "vatanf", FIXED(4)) 58 59// Hyperbolic Functions 60TLI_DEFINE_VECFUNC("sinhf", "vsinhf", FIXED(4)) 61TLI_DEFINE_VECFUNC("coshf", "vcoshf", FIXED(4)) 62TLI_DEFINE_VECFUNC("tanhf", "vtanhf", FIXED(4)) 63TLI_DEFINE_VECFUNC("asinhf", "vasinhf", FIXED(4)) 64TLI_DEFINE_VECFUNC("acoshf", "vacoshf", FIXED(4)) 65TLI_DEFINE_VECFUNC("atanhf", "vatanhf", FIXED(4)) 66 67#elif defined(TLI_DEFINE_DARWIN_LIBSYSTEM_M_VECFUNCS) 68// Darwin libsystem_m vector functions. 69 70// Exponential and Logarithmic Functions 71TLI_DEFINE_VECFUNC("exp", "_simd_exp_d2", FIXED(2)) 72TLI_DEFINE_VECFUNC("llvm.exp.f64", "_simd_exp_d2", FIXED(2)) 73TLI_DEFINE_VECFUNC("expf", "_simd_exp_f4", FIXED(4)) 74TLI_DEFINE_VECFUNC("llvm.exp.f32", "_simd_exp_f4", FIXED(4)) 75 76// Trigonometric Functions 77TLI_DEFINE_VECFUNC("acos", "_simd_acos_d2", FIXED(2)) 78TLI_DEFINE_VECFUNC("acosf", "_simd_acos_f4", FIXED(4)) 79TLI_DEFINE_VECFUNC("asin", "_simd_asin_d2", FIXED(2)) 80TLI_DEFINE_VECFUNC("asinf", "_simd_asin_f4", FIXED(4)) 81 82TLI_DEFINE_VECFUNC("atan", "_simd_atan_d2", FIXED(2)) 83TLI_DEFINE_VECFUNC("atanf", "_simd_atan_f4", FIXED(4)) 84TLI_DEFINE_VECFUNC("atan2", "_simd_atan2_d2", FIXED(2)) 85TLI_DEFINE_VECFUNC("atan2f", "_simd_atan2_f4", FIXED(4)) 86 87TLI_DEFINE_VECFUNC("cos", "_simd_cos_d2", FIXED(2)) 88TLI_DEFINE_VECFUNC("llvm.cos.f64", "_simd_cos_d2", FIXED(2)) 89TLI_DEFINE_VECFUNC("cosf", "_simd_cos_f4", FIXED(4)) 90TLI_DEFINE_VECFUNC("llvm.cos.f32", "_simd_cos_f4", FIXED(4)) 91 92TLI_DEFINE_VECFUNC("sin", "_simd_sin_d2", FIXED(2)) 93TLI_DEFINE_VECFUNC("llvm.sin.f64", "_simd_sin_d2", FIXED(2)) 94TLI_DEFINE_VECFUNC("sinf", "_simd_sin_f4", FIXED(4)) 95TLI_DEFINE_VECFUNC("llvm.sin.f32", "_simd_sin_f4", FIXED(4)) 96 97// Floating-Point Arithmetic and Auxiliary Functions 98TLI_DEFINE_VECFUNC("cbrt", "_simd_cbrt_d2", FIXED(2)) 99TLI_DEFINE_VECFUNC("cbrtf", "_simd_cbrt_f4", FIXED(4)) 100TLI_DEFINE_VECFUNC("erf", "_simd_erf_d2", FIXED(2)) 101TLI_DEFINE_VECFUNC("erff", "_simd_erf_f4", FIXED(4)) 102TLI_DEFINE_VECFUNC("pow", "_simd_pow_d2", FIXED(2)) 103TLI_DEFINE_VECFUNC("llvm.pow.f64", "_simd_pow_d2", FIXED(2)) 104TLI_DEFINE_VECFUNC("powf", "_simd_pow_f4", FIXED(4)) 105TLI_DEFINE_VECFUNC("llvm.pow.f32", "_simd_pow_f4", FIXED(4)) 106 107// Hyperbolic Functions 108TLI_DEFINE_VECFUNC("sinh", "_simd_sinh_d2", FIXED(2)) 109TLI_DEFINE_VECFUNC("sinhf", "_simd_sinh_f4", FIXED(4)) 110TLI_DEFINE_VECFUNC("cosh", "_simd_cosh_d2", FIXED(2)) 111TLI_DEFINE_VECFUNC("coshf", "_simd_cosh_f4", FIXED(4)) 112TLI_DEFINE_VECFUNC("tanh", "_simd_tanh_d2", FIXED(2)) 113TLI_DEFINE_VECFUNC("tanhf", "_simd_tanh_f4", FIXED(4)) 114TLI_DEFINE_VECFUNC("asinh", "_simd_asinh_d2", FIXED(2)) 115TLI_DEFINE_VECFUNC("asinhf", "_simd_asinh_f4", FIXED(4)) 116TLI_DEFINE_VECFUNC("acosh", "_simd_acosh_d2", FIXED(2)) 117TLI_DEFINE_VECFUNC("acoshf", "_simd_acosh_f4", FIXED(4)) 118TLI_DEFINE_VECFUNC("atanh", "_simd_atanh_d2", FIXED(2)) 119TLI_DEFINE_VECFUNC("atanhf", "_simd_atanh_f4", FIXED(4)) 120 121#elif defined(TLI_DEFINE_LIBMVEC_X86_VECFUNCS) 122// GLIBC Vector math Functions 123 124TLI_DEFINE_VECFUNC("sin", "_ZGVbN2v_sin", FIXED(2)) 125TLI_DEFINE_VECFUNC("sin", "_ZGVdN4v_sin", FIXED(4)) 126 127TLI_DEFINE_VECFUNC("sinf", "_ZGVbN4v_sinf", FIXED(4)) 128TLI_DEFINE_VECFUNC("sinf", "_ZGVdN8v_sinf", FIXED(8)) 129 130TLI_DEFINE_VECFUNC("llvm.sin.f64", "_ZGVbN2v_sin", FIXED(2)) 131TLI_DEFINE_VECFUNC("llvm.sin.f64", "_ZGVdN4v_sin", FIXED(4)) 132 133TLI_DEFINE_VECFUNC("llvm.sin.f32", "_ZGVbN4v_sinf", FIXED(4)) 134TLI_DEFINE_VECFUNC("llvm.sin.f32", "_ZGVdN8v_sinf", FIXED(8)) 135 136TLI_DEFINE_VECFUNC("cos", "_ZGVbN2v_cos", FIXED(2)) 137TLI_DEFINE_VECFUNC("cos", "_ZGVdN4v_cos", FIXED(4)) 138 139TLI_DEFINE_VECFUNC("cosf", "_ZGVbN4v_cosf", FIXED(4)) 140TLI_DEFINE_VECFUNC("cosf", "_ZGVdN8v_cosf", FIXED(8)) 141 142TLI_DEFINE_VECFUNC("llvm.cos.f64", "_ZGVbN2v_cos", FIXED(2)) 143TLI_DEFINE_VECFUNC("llvm.cos.f64", "_ZGVdN4v_cos", FIXED(4)) 144 145TLI_DEFINE_VECFUNC("llvm.cos.f32", "_ZGVbN4v_cosf", FIXED(4)) 146TLI_DEFINE_VECFUNC("llvm.cos.f32", "_ZGVdN8v_cosf", FIXED(8)) 147 148TLI_DEFINE_VECFUNC("pow", "_ZGVbN2vv_pow", FIXED(2)) 149TLI_DEFINE_VECFUNC("pow", "_ZGVdN4vv_pow", FIXED(4)) 150 151TLI_DEFINE_VECFUNC("powf", "_ZGVbN4vv_powf", FIXED(4)) 152TLI_DEFINE_VECFUNC("powf", "_ZGVdN8vv_powf", FIXED(8)) 153 154TLI_DEFINE_VECFUNC("__pow_finite", "_ZGVbN2vv___pow_finite", FIXED(2)) 155TLI_DEFINE_VECFUNC("__pow_finite", "_ZGVdN4vv___pow_finite", FIXED(4)) 156 157TLI_DEFINE_VECFUNC("__powf_finite", "_ZGVbN4vv___powf_finite", FIXED(4)) 158TLI_DEFINE_VECFUNC("__powf_finite", "_ZGVdN8vv___powf_finite", FIXED(8)) 159 160TLI_DEFINE_VECFUNC("llvm.pow.f64", "_ZGVbN2vv_pow", FIXED(2)) 161TLI_DEFINE_VECFUNC("llvm.pow.f64", "_ZGVdN4vv_pow", FIXED(4)) 162 163TLI_DEFINE_VECFUNC("llvm.pow.f32", "_ZGVbN4vv_powf", FIXED(4)) 164TLI_DEFINE_VECFUNC("llvm.pow.f32", "_ZGVdN8vv_powf", FIXED(8)) 165 166TLI_DEFINE_VECFUNC("exp", "_ZGVbN2v_exp", FIXED(2)) 167TLI_DEFINE_VECFUNC("exp", "_ZGVdN4v_exp", FIXED(4)) 168 169TLI_DEFINE_VECFUNC("expf", "_ZGVbN4v_expf", FIXED(4)) 170TLI_DEFINE_VECFUNC("expf", "_ZGVdN8v_expf", FIXED(8)) 171 172TLI_DEFINE_VECFUNC("__exp_finite", "_ZGVbN2v___exp_finite", FIXED(2)) 173TLI_DEFINE_VECFUNC("__exp_finite", "_ZGVdN4v___exp_finite", FIXED(4)) 174 175TLI_DEFINE_VECFUNC("__expf_finite", "_ZGVbN4v___expf_finite", FIXED(4)) 176TLI_DEFINE_VECFUNC("__expf_finite", "_ZGVdN8v___expf_finite", FIXED(8)) 177 178TLI_DEFINE_VECFUNC("llvm.exp.f64", "_ZGVbN2v_exp", FIXED(2)) 179TLI_DEFINE_VECFUNC("llvm.exp.f64", "_ZGVdN4v_exp", FIXED(4)) 180 181TLI_DEFINE_VECFUNC("llvm.exp.f32", "_ZGVbN4v_expf", FIXED(4)) 182TLI_DEFINE_VECFUNC("llvm.exp.f32", "_ZGVdN8v_expf", FIXED(8)) 183 184TLI_DEFINE_VECFUNC("log", "_ZGVbN2v_log", FIXED(2)) 185TLI_DEFINE_VECFUNC("log", "_ZGVdN4v_log", FIXED(4)) 186 187TLI_DEFINE_VECFUNC("logf", "_ZGVbN4v_logf", FIXED(4)) 188TLI_DEFINE_VECFUNC("logf", "_ZGVdN8v_logf", FIXED(8)) 189 190TLI_DEFINE_VECFUNC("__log_finite", "_ZGVbN2v___log_finite", FIXED(2)) 191TLI_DEFINE_VECFUNC("__log_finite", "_ZGVdN4v___log_finite", FIXED(4)) 192 193TLI_DEFINE_VECFUNC("__logf_finite", "_ZGVbN4v___logf_finite", FIXED(4)) 194TLI_DEFINE_VECFUNC("__logf_finite", "_ZGVdN8v___logf_finite", FIXED(8)) 195 196TLI_DEFINE_VECFUNC("llvm.log.f64", "_ZGVbN2v_log", FIXED(2)) 197TLI_DEFINE_VECFUNC("llvm.log.f64", "_ZGVdN4v_log", FIXED(4)) 198 199TLI_DEFINE_VECFUNC("llvm.log.f32", "_ZGVbN4v_logf", FIXED(4)) 200TLI_DEFINE_VECFUNC("llvm.log.f32", "_ZGVdN8v_logf", FIXED(8)) 201 202#elif defined(TLI_DEFINE_MASSV_VECFUNCS) 203// IBM MASS library's vector Functions 204 205// Floating-Point Arithmetic and Auxiliary Functions 206TLI_DEFINE_VECFUNC("cbrt", "__cbrtd2", FIXED(2)) 207TLI_DEFINE_VECFUNC("cbrtf", "__cbrtf4", FIXED(4)) 208TLI_DEFINE_VECFUNC("pow", "__powd2", FIXED(2)) 209TLI_DEFINE_VECFUNC("llvm.pow.f64", "__powd2", FIXED(2)) 210TLI_DEFINE_VECFUNC("powf", "__powf4", FIXED(4)) 211TLI_DEFINE_VECFUNC("llvm.pow.f32", "__powf4", FIXED(4)) 212 213// Exponential and Logarithmic Functions 214TLI_DEFINE_VECFUNC("exp", "__expd2", FIXED(2)) 215TLI_DEFINE_VECFUNC("llvm.exp.f64", "__expd2", FIXED(2)) 216TLI_DEFINE_VECFUNC("expf", "__expf4", FIXED(4)) 217TLI_DEFINE_VECFUNC("llvm.exp.f32", "__expf4", FIXED(4)) 218TLI_DEFINE_VECFUNC("exp2", "__exp2d2", FIXED(2)) 219TLI_DEFINE_VECFUNC("llvm.exp2.f64", "__exp2d2", FIXED(2)) 220TLI_DEFINE_VECFUNC("exp2f", "__exp2f4", FIXED(4)) 221TLI_DEFINE_VECFUNC("llvm.exp2.f32", "__exp2f4", FIXED(4)) 222TLI_DEFINE_VECFUNC("expm1", "__expm1d2", FIXED(2)) 223TLI_DEFINE_VECFUNC("expm1f", "__expm1f4", FIXED(4)) 224TLI_DEFINE_VECFUNC("log", "__logd2", FIXED(2)) 225TLI_DEFINE_VECFUNC("llvm.log.f64", "__logd2", FIXED(2)) 226TLI_DEFINE_VECFUNC("logf", "__logf4", FIXED(4)) 227TLI_DEFINE_VECFUNC("llvm.log.f32", "__logf4", FIXED(4)) 228TLI_DEFINE_VECFUNC("log1p", "__log1pd2", FIXED(2)) 229TLI_DEFINE_VECFUNC("log1pf", "__log1pf4", FIXED(4)) 230TLI_DEFINE_VECFUNC("log10", "__log10d2", FIXED(2)) 231TLI_DEFINE_VECFUNC("llvm.log10.f64", "__log10d2", FIXED(2)) 232TLI_DEFINE_VECFUNC("log10f", "__log10f4", FIXED(4)) 233TLI_DEFINE_VECFUNC("llvm.log10.f32", "__log10f4", FIXED(4)) 234TLI_DEFINE_VECFUNC("log2", "__log2d2", FIXED(2)) 235TLI_DEFINE_VECFUNC("llvm.log2.f64", "__log2d2", FIXED(2)) 236TLI_DEFINE_VECFUNC("log2f", "__log2f4", FIXED(4)) 237TLI_DEFINE_VECFUNC("llvm.log2.f32", "__log2f4", FIXED(4)) 238 239// Trigonometric Functions 240TLI_DEFINE_VECFUNC("sin", "__sind2", FIXED(2)) 241TLI_DEFINE_VECFUNC("llvm.sin.f64", "__sind2", FIXED(2)) 242TLI_DEFINE_VECFUNC("sinf", "__sinf4", FIXED(4)) 243TLI_DEFINE_VECFUNC("llvm.sin.f32", "__sinf4", FIXED(4)) 244TLI_DEFINE_VECFUNC("cos", "__cosd2", FIXED(2)) 245TLI_DEFINE_VECFUNC("llvm.cos.f64", "__cosd2", FIXED(2)) 246TLI_DEFINE_VECFUNC("cosf", "__cosf4", FIXED(4)) 247TLI_DEFINE_VECFUNC("llvm.cos.f32", "__cosf4", FIXED(4)) 248TLI_DEFINE_VECFUNC("tan", "__tand2", FIXED(2)) 249TLI_DEFINE_VECFUNC("tanf", "__tanf4", FIXED(4)) 250TLI_DEFINE_VECFUNC("asin", "__asind2", FIXED(2)) 251TLI_DEFINE_VECFUNC("asinf", "__asinf4", FIXED(4)) 252TLI_DEFINE_VECFUNC("acos", "__acosd2", FIXED(2)) 253TLI_DEFINE_VECFUNC("acosf", "__acosf4", FIXED(4)) 254TLI_DEFINE_VECFUNC("atan", "__atand2", FIXED(2)) 255TLI_DEFINE_VECFUNC("atanf", "__atanf4", FIXED(4)) 256TLI_DEFINE_VECFUNC("atan2", "__atan2d2", FIXED(2)) 257TLI_DEFINE_VECFUNC("atan2f", "__atan2f4", FIXED(4)) 258 259// Hyperbolic Functions 260TLI_DEFINE_VECFUNC("sinh", "__sinhd2", FIXED(2)) 261TLI_DEFINE_VECFUNC("sinhf", "__sinhf4", FIXED(4)) 262TLI_DEFINE_VECFUNC("cosh", "__coshd2", FIXED(2)) 263TLI_DEFINE_VECFUNC("coshf", "__coshf4", FIXED(4)) 264TLI_DEFINE_VECFUNC("tanh", "__tanhd2", FIXED(2)) 265TLI_DEFINE_VECFUNC("tanhf", "__tanhf4", FIXED(4)) 266TLI_DEFINE_VECFUNC("asinh", "__asinhd2", FIXED(2)) 267TLI_DEFINE_VECFUNC("asinhf", "__asinhf4", FIXED(4)) 268TLI_DEFINE_VECFUNC("acosh", "__acoshd2", FIXED(2)) 269TLI_DEFINE_VECFUNC("acoshf", "__acoshf4", FIXED(4)) 270TLI_DEFINE_VECFUNC("atanh", "__atanhd2", FIXED(2)) 271TLI_DEFINE_VECFUNC("atanhf", "__atanhf4", FIXED(4)) 272 273 274#elif defined(TLI_DEFINE_SVML_VECFUNCS) 275// Intel SVM library's Vector Functions 276 277TLI_DEFINE_VECFUNC("sin", "__svml_sin2", FIXED(2)) 278TLI_DEFINE_VECFUNC("sin", "__svml_sin4", FIXED(4)) 279TLI_DEFINE_VECFUNC("sin", "__svml_sin8", FIXED(8)) 280 281TLI_DEFINE_VECFUNC("sinf", "__svml_sinf4", FIXED(4)) 282TLI_DEFINE_VECFUNC("sinf", "__svml_sinf8", FIXED(8)) 283TLI_DEFINE_VECFUNC("sinf", "__svml_sinf16", FIXED(16)) 284 285TLI_DEFINE_VECFUNC("llvm.sin.f64", "__svml_sin2", FIXED(2)) 286TLI_DEFINE_VECFUNC("llvm.sin.f64", "__svml_sin4", FIXED(4)) 287TLI_DEFINE_VECFUNC("llvm.sin.f64", "__svml_sin8", FIXED(8)) 288 289TLI_DEFINE_VECFUNC("llvm.sin.f32", "__svml_sinf4", FIXED(4)) 290TLI_DEFINE_VECFUNC("llvm.sin.f32", "__svml_sinf8", FIXED(8)) 291TLI_DEFINE_VECFUNC("llvm.sin.f32", "__svml_sinf16", FIXED(16)) 292 293TLI_DEFINE_VECFUNC("cos", "__svml_cos2", FIXED(2)) 294TLI_DEFINE_VECFUNC("cos", "__svml_cos4", FIXED(4)) 295TLI_DEFINE_VECFUNC("cos", "__svml_cos8", FIXED(8)) 296 297TLI_DEFINE_VECFUNC("cosf", "__svml_cosf4", FIXED(4)) 298TLI_DEFINE_VECFUNC("cosf", "__svml_cosf8", FIXED(8)) 299TLI_DEFINE_VECFUNC("cosf", "__svml_cosf16", FIXED(16)) 300 301TLI_DEFINE_VECFUNC("llvm.cos.f64", "__svml_cos2", FIXED(2)) 302TLI_DEFINE_VECFUNC("llvm.cos.f64", "__svml_cos4", FIXED(4)) 303TLI_DEFINE_VECFUNC("llvm.cos.f64", "__svml_cos8", FIXED(8)) 304 305TLI_DEFINE_VECFUNC("llvm.cos.f32", "__svml_cosf4", FIXED(4)) 306TLI_DEFINE_VECFUNC("llvm.cos.f32", "__svml_cosf8", FIXED(8)) 307TLI_DEFINE_VECFUNC("llvm.cos.f32", "__svml_cosf16", FIXED(16)) 308 309TLI_DEFINE_VECFUNC("pow", "__svml_pow2", FIXED(2)) 310TLI_DEFINE_VECFUNC("pow", "__svml_pow4", FIXED(4)) 311TLI_DEFINE_VECFUNC("pow", "__svml_pow8", FIXED(8)) 312 313TLI_DEFINE_VECFUNC("powf", "__svml_powf4", FIXED(4)) 314TLI_DEFINE_VECFUNC("powf", "__svml_powf8", FIXED(8)) 315TLI_DEFINE_VECFUNC("powf", "__svml_powf16", FIXED(16)) 316 317TLI_DEFINE_VECFUNC("__pow_finite", "__svml_pow2", FIXED(2)) 318TLI_DEFINE_VECFUNC("__pow_finite", "__svml_pow4", FIXED(4)) 319TLI_DEFINE_VECFUNC("__pow_finite", "__svml_pow8", FIXED(8)) 320 321TLI_DEFINE_VECFUNC("__powf_finite", "__svml_powf4", FIXED(4)) 322TLI_DEFINE_VECFUNC("__powf_finite", "__svml_powf8", FIXED(8)) 323TLI_DEFINE_VECFUNC("__powf_finite", "__svml_powf16", FIXED(16)) 324 325TLI_DEFINE_VECFUNC("llvm.pow.f64", "__svml_pow2", FIXED(2)) 326TLI_DEFINE_VECFUNC("llvm.pow.f64", "__svml_pow4", FIXED(4)) 327TLI_DEFINE_VECFUNC("llvm.pow.f64", "__svml_pow8", FIXED(8)) 328 329TLI_DEFINE_VECFUNC("llvm.pow.f32", "__svml_powf4", FIXED(4)) 330TLI_DEFINE_VECFUNC("llvm.pow.f32", "__svml_powf8", FIXED(8)) 331TLI_DEFINE_VECFUNC("llvm.pow.f32", "__svml_powf16", FIXED(16)) 332 333TLI_DEFINE_VECFUNC("exp", "__svml_exp2", FIXED(2)) 334TLI_DEFINE_VECFUNC("exp", "__svml_exp4", FIXED(4)) 335TLI_DEFINE_VECFUNC("exp", "__svml_exp8", FIXED(8)) 336 337TLI_DEFINE_VECFUNC("expf", "__svml_expf4", FIXED(4)) 338TLI_DEFINE_VECFUNC("expf", "__svml_expf8", FIXED(8)) 339TLI_DEFINE_VECFUNC("expf", "__svml_expf16", FIXED(16)) 340 341TLI_DEFINE_VECFUNC("__exp_finite", "__svml_exp2", FIXED(2)) 342TLI_DEFINE_VECFUNC("__exp_finite", "__svml_exp4", FIXED(4)) 343TLI_DEFINE_VECFUNC("__exp_finite", "__svml_exp8", FIXED(8)) 344 345TLI_DEFINE_VECFUNC("__expf_finite", "__svml_expf4", FIXED(4)) 346TLI_DEFINE_VECFUNC("__expf_finite", "__svml_expf8", FIXED(8)) 347TLI_DEFINE_VECFUNC("__expf_finite", "__svml_expf16", FIXED(16)) 348 349TLI_DEFINE_VECFUNC("llvm.exp.f64", "__svml_exp2", FIXED(2)) 350TLI_DEFINE_VECFUNC("llvm.exp.f64", "__svml_exp4", FIXED(4)) 351TLI_DEFINE_VECFUNC("llvm.exp.f64", "__svml_exp8", FIXED(8)) 352 353TLI_DEFINE_VECFUNC("llvm.exp.f32", "__svml_expf4", FIXED(4)) 354TLI_DEFINE_VECFUNC("llvm.exp.f32", "__svml_expf8", FIXED(8)) 355TLI_DEFINE_VECFUNC("llvm.exp.f32", "__svml_expf16", FIXED(16)) 356 357TLI_DEFINE_VECFUNC("log", "__svml_log2", FIXED(2)) 358TLI_DEFINE_VECFUNC("log", "__svml_log4", FIXED(4)) 359TLI_DEFINE_VECFUNC("log", "__svml_log8", FIXED(8)) 360 361TLI_DEFINE_VECFUNC("logf", "__svml_logf4", FIXED(4)) 362TLI_DEFINE_VECFUNC("logf", "__svml_logf8", FIXED(8)) 363TLI_DEFINE_VECFUNC("logf", "__svml_logf16", FIXED(16)) 364 365TLI_DEFINE_VECFUNC("__log_finite", "__svml_log2", FIXED(2)) 366TLI_DEFINE_VECFUNC("__log_finite", "__svml_log4", FIXED(4)) 367TLI_DEFINE_VECFUNC("__log_finite", "__svml_log8", FIXED(8)) 368 369TLI_DEFINE_VECFUNC("__logf_finite", "__svml_logf4", FIXED(4)) 370TLI_DEFINE_VECFUNC("__logf_finite", "__svml_logf8", FIXED(8)) 371TLI_DEFINE_VECFUNC("__logf_finite", "__svml_logf16", FIXED(16)) 372 373TLI_DEFINE_VECFUNC("llvm.log.f64", "__svml_log2", FIXED(2)) 374TLI_DEFINE_VECFUNC("llvm.log.f64", "__svml_log4", FIXED(4)) 375TLI_DEFINE_VECFUNC("llvm.log.f64", "__svml_log8", FIXED(8)) 376 377TLI_DEFINE_VECFUNC("llvm.log.f32", "__svml_logf4", FIXED(4)) 378TLI_DEFINE_VECFUNC("llvm.log.f32", "__svml_logf8", FIXED(8)) 379TLI_DEFINE_VECFUNC("llvm.log.f32", "__svml_logf16", FIXED(16)) 380 381TLI_DEFINE_VECFUNC("log2", "__svml_log22", FIXED(2)) 382TLI_DEFINE_VECFUNC("log2", "__svml_log24", FIXED(4)) 383TLI_DEFINE_VECFUNC("log2", "__svml_log28", FIXED(8)) 384 385TLI_DEFINE_VECFUNC("log2f", "__svml_log2f4", FIXED(4)) 386TLI_DEFINE_VECFUNC("log2f", "__svml_log2f8", FIXED(8)) 387TLI_DEFINE_VECFUNC("log2f", "__svml_log2f16", FIXED(16)) 388 389TLI_DEFINE_VECFUNC("__log2_finite", "__svml_log22", FIXED(2)) 390TLI_DEFINE_VECFUNC("__log2_finite", "__svml_log24", FIXED(4)) 391TLI_DEFINE_VECFUNC("__log2_finite", "__svml_log28", FIXED(8)) 392 393TLI_DEFINE_VECFUNC("__log2f_finite", "__svml_log2f4", FIXED(4)) 394TLI_DEFINE_VECFUNC("__log2f_finite", "__svml_log2f8", FIXED(8)) 395TLI_DEFINE_VECFUNC("__log2f_finite", "__svml_log2f16", FIXED(16)) 396 397TLI_DEFINE_VECFUNC("llvm.log2.f64", "__svml_log22", FIXED(2)) 398TLI_DEFINE_VECFUNC("llvm.log2.f64", "__svml_log24", FIXED(4)) 399TLI_DEFINE_VECFUNC("llvm.log2.f64", "__svml_log28", FIXED(8)) 400 401TLI_DEFINE_VECFUNC("llvm.log2.f32", "__svml_log2f4", FIXED(4)) 402TLI_DEFINE_VECFUNC("llvm.log2.f32", "__svml_log2f8", FIXED(8)) 403TLI_DEFINE_VECFUNC("llvm.log2.f32", "__svml_log2f16", FIXED(16)) 404 405TLI_DEFINE_VECFUNC("log10", "__svml_log102", FIXED(2)) 406TLI_DEFINE_VECFUNC("log10", "__svml_log104", FIXED(4)) 407TLI_DEFINE_VECFUNC("log10", "__svml_log108", FIXED(8)) 408 409TLI_DEFINE_VECFUNC("log10f", "__svml_log10f4", FIXED(4)) 410TLI_DEFINE_VECFUNC("log10f", "__svml_log10f8", FIXED(8)) 411TLI_DEFINE_VECFUNC("log10f", "__svml_log10f16", FIXED(16)) 412 413TLI_DEFINE_VECFUNC("__log10_finite", "__svml_log102", FIXED(2)) 414TLI_DEFINE_VECFUNC("__log10_finite", "__svml_log104", FIXED(4)) 415TLI_DEFINE_VECFUNC("__log10_finite", "__svml_log108", FIXED(8)) 416 417TLI_DEFINE_VECFUNC("__log10f_finite", "__svml_log10f4", FIXED(4)) 418TLI_DEFINE_VECFUNC("__log10f_finite", "__svml_log10f8", FIXED(8)) 419TLI_DEFINE_VECFUNC("__log10f_finite", "__svml_log10f16", FIXED(16)) 420 421TLI_DEFINE_VECFUNC("llvm.log10.f64", "__svml_log102", FIXED(2)) 422TLI_DEFINE_VECFUNC("llvm.log10.f64", "__svml_log104", FIXED(4)) 423TLI_DEFINE_VECFUNC("llvm.log10.f64", "__svml_log108", FIXED(8)) 424 425TLI_DEFINE_VECFUNC("llvm.log10.f32", "__svml_log10f4", FIXED(4)) 426TLI_DEFINE_VECFUNC("llvm.log10.f32", "__svml_log10f8", FIXED(8)) 427TLI_DEFINE_VECFUNC("llvm.log10.f32", "__svml_log10f16", FIXED(16)) 428 429TLI_DEFINE_VECFUNC("sqrt", "__svml_sqrt2", FIXED(2)) 430TLI_DEFINE_VECFUNC("sqrt", "__svml_sqrt4", FIXED(4)) 431TLI_DEFINE_VECFUNC("sqrt", "__svml_sqrt8", FIXED(8)) 432 433TLI_DEFINE_VECFUNC("sqrtf", "__svml_sqrtf4", FIXED(4)) 434TLI_DEFINE_VECFUNC("sqrtf", "__svml_sqrtf8", FIXED(8)) 435TLI_DEFINE_VECFUNC("sqrtf", "__svml_sqrtf16", FIXED(16)) 436 437TLI_DEFINE_VECFUNC("__sqrt_finite", "__svml_sqrt2", FIXED(2)) 438TLI_DEFINE_VECFUNC("__sqrt_finite", "__svml_sqrt4", FIXED(4)) 439TLI_DEFINE_VECFUNC("__sqrt_finite", "__svml_sqrt8", FIXED(8)) 440 441TLI_DEFINE_VECFUNC("__sqrtf_finite", "__svml_sqrtf4", FIXED(4)) 442TLI_DEFINE_VECFUNC("__sqrtf_finite", "__svml_sqrtf8", FIXED(8)) 443TLI_DEFINE_VECFUNC("__sqrtf_finite", "__svml_sqrtf16", FIXED(16)) 444 445TLI_DEFINE_VECFUNC("exp2", "__svml_exp22", FIXED(2)) 446TLI_DEFINE_VECFUNC("exp2", "__svml_exp24", FIXED(4)) 447TLI_DEFINE_VECFUNC("exp2", "__svml_exp28", FIXED(8)) 448 449TLI_DEFINE_VECFUNC("exp2f", "__svml_exp2f4", FIXED(4)) 450TLI_DEFINE_VECFUNC("exp2f", "__svml_exp2f8", FIXED(8)) 451TLI_DEFINE_VECFUNC("exp2f", "__svml_exp2f16", FIXED(16)) 452 453TLI_DEFINE_VECFUNC("llvm.exp2.f64", "__svml_exp22", FIXED(2)) 454TLI_DEFINE_VECFUNC("llvm.exp2.f64", "__svml_exp24", FIXED(4)) 455TLI_DEFINE_VECFUNC("llvm.exp2.f64", "__svml_exp28", FIXED(8)) 456 457TLI_DEFINE_VECFUNC("llvm.exp2.f32", "__svml_exp2f4", FIXED(4)) 458TLI_DEFINE_VECFUNC("llvm.exp2.f32", "__svml_exp2f8", FIXED(8)) 459TLI_DEFINE_VECFUNC("llvm.exp2.f32", "__svml_exp2f16", FIXED(16)) 460 461TLI_DEFINE_VECFUNC("__exp2_finite", "__svml_exp22", FIXED(2)) 462TLI_DEFINE_VECFUNC("__exp2_finite", "__svml_exp24", FIXED(4)) 463TLI_DEFINE_VECFUNC("__exp2_finite", "__svml_exp28", FIXED(8)) 464 465TLI_DEFINE_VECFUNC("__exp2f_finite", "__svml_exp2f4", FIXED(4)) 466TLI_DEFINE_VECFUNC("__exp2f_finite", "__svml_exp2f8", FIXED(8)) 467TLI_DEFINE_VECFUNC("__exp2f_finite", "__svml_exp2f16", FIXED(16)) 468 469#else 470#error "Must choose which vector library functions are to be defined." 471#endif 472 473#undef TLI_DEFINE_VECFUNC 474#undef TLI_DEFINE_ACCELERATE_VECFUNCS 475#undef TLI_DEFINE_DARWIN_LIBSYSTEM_M_VECFUNCS 476#undef TLI_DEFINE_LIBMVEC_X86_VECFUNCS 477#undef TLI_DEFINE_MASSV_VECFUNCS 478#undef TLI_DEFINE_SVML_VECFUNCS 479#undef TLI_DEFINE_MASSV_VECFUNCS_NAMES 480