[PATCH] D156178: [HLSL] add pow library function

Chris Bieneman via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Jul 24 16:20:28 PDT 2023


beanz added inline comments.


================
Comment at: clang/test/CodeGenHLSL/builtins/pow.hlsl:6
+// RUN:   dxil-pc-shadermodel6.3-library %s -emit-llvm -disable-llvm-passes \
+// RUN:   -D__HLSL_ENABLE_16_BIT -o - | FileCheck %s --check-prefix=NO_HALF
+
----------------
Does this need to set `-D__HLSL_ENABLE_16_BIT`? If 16-bit types are disabled, this should result in `half` being 32-bit right?


================
Comment at: clang/test/CodeGenHLSL/builtins/pow.hlsl:12
+// NO_HALF: call float @llvm.pow.f32(
+half test_pow_half(half p0, half p1)
+{
----------------
nit: can you clang-format this source?


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D156178/new/

https://reviews.llvm.org/D156178



More information about the cfe-commits mailing list