[clang] [llvm] [HLSL] Move `lerp` implementation to header files (PR #215692)

Kaitlin Peng via llvm-commits llvm-commits at lists.llvm.org
Tue Aug 11 17:54:02 PDT 2026


================
@@ -1,58 +1,59 @@
 // RUN: %clang_cc1 -finclude-default-header -x hlsl -triple \
 // RUN:   dxil-pc-shadermodel6.3-library %s -fnative-half-type -fnative-int16-type \
-// RUN:   -emit-llvm -disable-llvm-passes -o - | FileCheck %s \
-// RUN:   --check-prefixes=CHECK,NATIVE_HALF \
-// RUN:   -DFNATTRS="noundef nofpclass(nan inf)" -DTARGET=dx
-// RUN: %clang_cc1 -finclude-default-header -x hlsl -triple \
----------------
kmpeng wrote:

`NO_HALF` was only there to check for `@llvm.dx.lerp.f16` vs `.f32`. Now that `lerp` is implemented in the header, running without `-fnative-half-type` just promotes `half` -> `float` and emits the same `fsub`/`fmul`/`fadd` the float tests already cover

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


More information about the llvm-commits mailing list