[clang] [llvm] [HLSL] Implement support for HLSL intrinsic - saturate (PR #104619)

Farzon Lotfi via llvm-commits llvm-commits at lists.llvm.org
Mon Aug 19 12:52:30 PDT 2024


================
@@ -0,0 +1,69 @@
+; RUN: opt -S -dxil-op-lower -mtriple=dxil-pc-shadermodel6.3-library %s | FileCheck %s
+; Make sure the intrinsic dx.saturate is to appropriate DXIL op for half/float/double data types.
+
+target datalayout = "e-m:e-p:32:32-i1:32-i8:8-i16:16-i32:32-i64:64-f16:16-f32:32-f64:64-n8:16:32:64"
+target triple = "dxilv1.6-unknown-shadermodel6.6-library"
----------------
farzonl wrote:

your triple via the  opt call is `dxil-pc-shadermodel6.3-library`.  We ussualy either specify the triple here or via the command line to avoid inconsistencies like this. I prefer the command line so recommand deleting this line.

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


More information about the llvm-commits mailing list