[llvm] [clang] Adding support of AMDLIBM vector library (PR #78560)

Rohit Aggarwal via cfe-commits cfe-commits at lists.llvm.org
Tue Jan 30 07:50:13 PST 2024


================
@@ -0,0 +1,332 @@
+; RUN: opt -vector-library=AMDLIBM -passes=inject-tli-mappings,loop-vectorize -S < %s | FileCheck %s
+
+; Test to verify that when math headers are built with
+; __FINITE_MATH_ONLY__ enabled, causing use of __<func>_finite
+; function versions, vectorization can map these to vector versions.
+
+target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"
+target triple = "x86_64-unknown-linux-gnu"
+
+declare float @__expf_finite(float) #0
+
+; CHECK-LABEL: @exp_f32
+; CHECK: <4 x float> @amd_vrs4_expf
----------------
rohitaggarwal007 wrote:

Added RUN for avx512 in amdlibm-calls.ll

https://github.com/llvm/llvm-project/pull/78560


More information about the cfe-commits mailing list