[PATCH] D132711: [HLSL] add sqrt library function
Greg Roth via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Fri Aug 26 15:17:38 PDT 2022
pow2clk added a comment.
A very minor suggestion. This looks pretty straightforward.
================
Comment at: clang/test/CodeGenHLSL/builtins/sqrt.hlsl:6
+// RUN: dxil-pc-shadermodel6.3-library %s -emit-llvm -disable-llvm-passes \
+// RUN: -o - | FileCheck %s --check-prefix=NO_HALF
+
----------------
The -fnative-half-type suggests that you're readying this for when 16-bit types are available. That's fine, but in the spirit of starting as early as possible as we tend to do with these, you might want to target shadermodel6.2 instead since that's where they were introduced and sqrt is as old as HLSL 1.0 AFAIK.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D132711/new/
https://reviews.llvm.org/D132711
More information about the cfe-commits
mailing list