[clang] [llvm] [DirectX][DXIL] Set DXIL Version in DXIL target triple based on shader model version (PR #90809)
S. Bharadwaj Yadavalli via cfe-commits
cfe-commits at lists.llvm.org
Mon May 6 13:54:00 PDT 2024
================
@@ -2454,4 +2454,19 @@ TEST(TripleTest, isArmMClass) {
EXPECT_TRUE(T.isArmMClass());
}
}
+
+TEST(TripleTest, DXILNormaizeWithVersion) {
+ EXPECT_EQ("dxilv1.0-unknown-shadermodel6.0",
+ Triple::normalize("dxilv1.0--shadermodel6.0"));
----------------
bharadwajy wrote:
> What will Triple::normalize("dxilv1.0--shadermodel6.2") expect equal? "dxilv1.2-unknown-shadermodel6.2"?
No. Since DXIL version is specified in the triple, it is honored as is. So, it will be `dxilv1.0-unknown-shadermodel6.2`
https://github.com/llvm/llvm-project/pull/90809
More information about the cfe-commits
mailing list