From 7ad6a0acb327d2f976e8bb8a864119fc31986efc Mon Sep 17 00:00:00 2001 From: Alex Sepkowski <5620315+alsepkow@users.noreply.github.com> Date: Wed, 14 Jan 2026 17:57:24 -0800 Subject: [PATCH 1/4] Dxil 1.9 --- include/dxc/DXIL/DxilConstants.h | 2 +- include/dxc/DXIL/DxilShaderModel.h | 5 +- include/dxc/Support/HLSLOptions.td | 2 +- lib/DXIL/DxilShaderModel.cpp | 237 +++++++++++++---------------- utils/hct/hctdb_instrhelp.py | 2 +- 5 files changed, 111 insertions(+), 137 deletions(-) diff --git a/include/dxc/DXIL/DxilConstants.h b/include/dxc/DXIL/DxilConstants.h index 2c00080ada..949795c110 100644 --- a/include/dxc/DXIL/DxilConstants.h +++ b/include/dxc/DXIL/DxilConstants.h @@ -29,7 +29,7 @@ namespace DXIL { const unsigned kDxilMajor = 1; /* hctdb_instrhelp.get_dxil_version_minor()*/ // VALRULE-TEXT:BEGIN -const unsigned kDxilMinor = 10; +const unsigned kDxilMinor = 9; // VALRULE-TEXT:END inline unsigned MakeDxilVersion(unsigned DxilMajor, unsigned DxilMinor) { diff --git a/include/dxc/DXIL/DxilShaderModel.h b/include/dxc/DXIL/DxilShaderModel.h index ff9ef39b99..380fb1aa32 100644 --- a/include/dxc/DXIL/DxilShaderModel.h +++ b/include/dxc/DXIL/DxilShaderModel.h @@ -33,7 +33,7 @@ class ShaderModel { // clang-format on // VALRULE-TEXT:BEGIN static const unsigned kHighestMajor = 6; - static const unsigned kHighestMinor = 10; + static const unsigned kHighestMinor = 9; // VALRULE-TEXT:END // Major/Minor version of highest released shader model @@ -87,7 +87,6 @@ class ShaderModel { bool IsSM67Plus() const { return IsSMAtLeast(6, 7); } bool IsSM68Plus() const { return IsSMAtLeast(6, 8); } bool IsSM69Plus() const { return IsSMAtLeast(6, 9); } - bool IsSM610Plus() const { return IsSMAtLeast(6, 10); } // VALRULE-TEXT:END const char *GetName() const { return m_pszName; } const char *GetKindName() const; @@ -139,7 +138,7 @@ class ShaderModel { bool m_bTypedUavs, unsigned m_UAVRegsLim); /* hctdb_instrhelp.get_num_shader_models()*/ // VALRULE-TEXT:BEGIN - static const unsigned kNumShaderModels = 116; + static const unsigned kNumShaderModels = 107; // VALRULE-TEXT:END static const ShaderModel ms_ShaderModels[kNumShaderModels]; diff --git a/include/dxc/Support/HLSLOptions.td b/include/dxc/Support/HLSLOptions.td index cd7dfb2f0c..40182f85b9 100644 --- a/include/dxc/Support/HLSLOptions.td +++ b/include/dxc/Support/HLSLOptions.td @@ -451,7 +451,7 @@ def fvk_bind_counter_heap : MultiArg<["-"], "fvk-bind-counter-heap", 2>, MetaVar def target_profile : JoinedOrSeparate<["-", "/"], "T">, Flags<[CoreOption]>, Group, MetaVarName<"">, /* hctdb_instrhelp.get_target_profiles()*/ // VALRULE-TEXT:BEGIN - HelpText<"Set target profile. \n\t: ps_6_0, ps_6_1, ps_6_2, ps_6_3, ps_6_4, ps_6_5, ps_6_6, ps_6_7, ps_6_8, ps_6_9, ps_6_10, \n\t\t vs_6_0, vs_6_1, vs_6_2, vs_6_3, vs_6_4, vs_6_5, vs_6_6, vs_6_7, vs_6_8, vs_6_9, vs_6_10, \n\t\t gs_6_0, gs_6_1, gs_6_2, gs_6_3, gs_6_4, gs_6_5, gs_6_6, gs_6_7, gs_6_8, gs_6_9, gs_6_10, \n\t\t hs_6_0, hs_6_1, hs_6_2, hs_6_3, hs_6_4, hs_6_5, hs_6_6, hs_6_7, hs_6_8, hs_6_9, hs_6_10, \n\t\t ds_6_0, ds_6_1, ds_6_2, ds_6_3, ds_6_4, ds_6_5, ds_6_6, ds_6_7, ds_6_8, ds_6_9, ds_6_10, \n\t\t cs_6_0, cs_6_1, cs_6_2, cs_6_3, cs_6_4, cs_6_5, cs_6_6, cs_6_7, cs_6_8, cs_6_9, cs_6_10, \n\t\t lib_6_1, lib_6_2, lib_6_3, lib_6_4, lib_6_5, lib_6_6, lib_6_7, lib_6_8, lib_6_9, lib_6_10, \n\t\t ms_6_5, ms_6_6, ms_6_7, ms_6_8, ms_6_9, ms_6_10, \n\t\t as_6_5, as_6_6, as_6_7, as_6_8, as_6_9, as_6_10, \n\t\t ">; + HelpText<"Set target profile. \n\t: ps_6_0, ps_6_1, ps_6_2, ps_6_3, ps_6_4, ps_6_5, ps_6_6, ps_6_7, ps_6_8, ps_6_9, \n\t\t vs_6_0, vs_6_1, vs_6_2, vs_6_3, vs_6_4, vs_6_5, vs_6_6, vs_6_7, vs_6_8, vs_6_9, \n\t\t gs_6_0, gs_6_1, gs_6_2, gs_6_3, gs_6_4, gs_6_5, gs_6_6, gs_6_7, gs_6_8, gs_6_9, \n\t\t hs_6_0, hs_6_1, hs_6_2, hs_6_3, hs_6_4, hs_6_5, hs_6_6, hs_6_7, hs_6_8, hs_6_9, \n\t\t ds_6_0, ds_6_1, ds_6_2, ds_6_3, ds_6_4, ds_6_5, ds_6_6, ds_6_7, ds_6_8, ds_6_9, \n\t\t cs_6_0, cs_6_1, cs_6_2, cs_6_3, cs_6_4, cs_6_5, cs_6_6, cs_6_7, cs_6_8, cs_6_9, \n\t\t lib_6_1, lib_6_2, lib_6_3, lib_6_4, lib_6_5, lib_6_6, lib_6_7, lib_6_8, lib_6_9, \n\t\t ms_6_5, ms_6_6, ms_6_7, ms_6_8, ms_6_9, \n\t\t as_6_5, as_6_6, as_6_7, as_6_8, as_6_9, \n\t\t ">; // VALRULE-TEXT:END def entrypoint : JoinedOrSeparate<["-", "/"], "E">, Flags<[CoreOption, RewriteOption]>, Group, HelpText<"Entry point name">; diff --git a/lib/DXIL/DxilShaderModel.cpp b/lib/DXIL/DxilShaderModel.cpp index e70a3b44c9..06cc6e633c 100644 --- a/lib/DXIL/DxilShaderModel.cpp +++ b/lib/DXIL/DxilShaderModel.cpp @@ -65,7 +65,6 @@ bool ShaderModel::IsValidForDxil() const { case 7: case 8: case 9: - case 10: // VALRULE-TEXT:END return true; case kOfflineMinor: @@ -80,122 +79,113 @@ const ShaderModel *ShaderModel::Get(Kind Kind, unsigned Major, unsigned Minor) { /* hctdb_instrhelp.get_shader_model_get()*/ // VALRULE-TEXT:BEGIN const static std::pair hashToIdxMap[] = { - {1024, 0}, // ps_4_0 - {1025, 1}, // ps_4_1 - {1280, 2}, // ps_5_0 - {1281, 3}, // ps_5_1 - {1536, 4}, // ps_6_0 - {1537, 5}, // ps_6_1 - {1538, 6}, // ps_6_2 - {1539, 7}, // ps_6_3 - {1540, 8}, // ps_6_4 - {1541, 9}, // ps_6_5 - {1542, 10}, // ps_6_6 - {1543, 11}, // ps_6_7 - {1544, 12}, // ps_6_8 - {1545, 13}, // ps_6_9 - {1546, 14}, // ps_6_10 - {66560, 15}, // vs_4_0 - {66561, 16}, // vs_4_1 - {66816, 17}, // vs_5_0 - {66817, 18}, // vs_5_1 - {67072, 19}, // vs_6_0 - {67073, 20}, // vs_6_1 - {67074, 21}, // vs_6_2 - {67075, 22}, // vs_6_3 - {67076, 23}, // vs_6_4 - {67077, 24}, // vs_6_5 - {67078, 25}, // vs_6_6 - {67079, 26}, // vs_6_7 - {67080, 27}, // vs_6_8 - {67081, 28}, // vs_6_9 - {67082, 29}, // vs_6_10 - {132096, 30}, // gs_4_0 - {132097, 31}, // gs_4_1 - {132352, 32}, // gs_5_0 - {132353, 33}, // gs_5_1 - {132608, 34}, // gs_6_0 - {132609, 35}, // gs_6_1 - {132610, 36}, // gs_6_2 - {132611, 37}, // gs_6_3 - {132612, 38}, // gs_6_4 - {132613, 39}, // gs_6_5 - {132614, 40}, // gs_6_6 - {132615, 41}, // gs_6_7 - {132616, 42}, // gs_6_8 - {132617, 43}, // gs_6_9 - {132618, 44}, // gs_6_10 - {197632, 45}, // hs_4_0 - {197633, 46}, // hs_4_1 - {197888, 47}, // hs_5_0 - {197889, 48}, // hs_5_1 - {198144, 49}, // hs_6_0 - {198145, 50}, // hs_6_1 - {198146, 51}, // hs_6_2 - {198147, 52}, // hs_6_3 - {198148, 53}, // hs_6_4 - {198149, 54}, // hs_6_5 - {198150, 55}, // hs_6_6 - {198151, 56}, // hs_6_7 - {198152, 57}, // hs_6_8 - {198153, 58}, // hs_6_9 - {198154, 59}, // hs_6_10 - {263168, 60}, // ds_4_0 - {263169, 61}, // ds_4_1 - {263424, 62}, // ds_5_0 - {263425, 63}, // ds_5_1 - {263680, 64}, // ds_6_0 - {263681, 65}, // ds_6_1 - {263682, 66}, // ds_6_2 - {263683, 67}, // ds_6_3 - {263684, 68}, // ds_6_4 - {263685, 69}, // ds_6_5 - {263686, 70}, // ds_6_6 - {263687, 71}, // ds_6_7 - {263688, 72}, // ds_6_8 - {263689, 73}, // ds_6_9 - {263690, 74}, // ds_6_10 - {328704, 75}, // cs_4_0 - {328705, 76}, // cs_4_1 - {328960, 77}, // cs_5_0 - {328961, 78}, // cs_5_1 - {329216, 79}, // cs_6_0 - {329217, 80}, // cs_6_1 - {329218, 81}, // cs_6_2 - {329219, 82}, // cs_6_3 - {329220, 83}, // cs_6_4 - {329221, 84}, // cs_6_5 - {329222, 85}, // cs_6_6 - {329223, 86}, // cs_6_7 - {329224, 87}, // cs_6_8 - {329225, 88}, // cs_6_9 - {329226, 89}, // cs_6_10 - {394241, 90}, // lib_4_1 - {394497, 91}, // lib_5_1 - {394753, 92}, // lib_6_1 - {394754, 93}, // lib_6_2 - {394755, 94}, // lib_6_3 - {394756, 95}, // lib_6_4 - {394757, 96}, // lib_6_5 - {394758, 97}, // lib_6_6 - {394759, 98}, // lib_6_7 - {394760, 99}, // lib_6_8 - {394761, 100}, // lib_6_9 - {394762, 101}, // lib_6_10 + {1024, 0}, // ps_4_0 + {1025, 1}, // ps_4_1 + {1280, 2}, // ps_5_0 + {1281, 3}, // ps_5_1 + {1536, 4}, // ps_6_0 + {1537, 5}, // ps_6_1 + {1538, 6}, // ps_6_2 + {1539, 7}, // ps_6_3 + {1540, 8}, // ps_6_4 + {1541, 9}, // ps_6_5 + {1542, 10}, // ps_6_6 + {1543, 11}, // ps_6_7 + {1544, 12}, // ps_6_8 + {1545, 13}, // ps_6_9 + {66560, 14}, // vs_4_0 + {66561, 15}, // vs_4_1 + {66816, 16}, // vs_5_0 + {66817, 17}, // vs_5_1 + {67072, 18}, // vs_6_0 + {67073, 19}, // vs_6_1 + {67074, 20}, // vs_6_2 + {67075, 21}, // vs_6_3 + {67076, 22}, // vs_6_4 + {67077, 23}, // vs_6_5 + {67078, 24}, // vs_6_6 + {67079, 25}, // vs_6_7 + {67080, 26}, // vs_6_8 + {67081, 27}, // vs_6_9 + {132096, 28}, // gs_4_0 + {132097, 29}, // gs_4_1 + {132352, 30}, // gs_5_0 + {132353, 31}, // gs_5_1 + {132608, 32}, // gs_6_0 + {132609, 33}, // gs_6_1 + {132610, 34}, // gs_6_2 + {132611, 35}, // gs_6_3 + {132612, 36}, // gs_6_4 + {132613, 37}, // gs_6_5 + {132614, 38}, // gs_6_6 + {132615, 39}, // gs_6_7 + {132616, 40}, // gs_6_8 + {132617, 41}, // gs_6_9 + {197632, 42}, // hs_4_0 + {197633, 43}, // hs_4_1 + {197888, 44}, // hs_5_0 + {197889, 45}, // hs_5_1 + {198144, 46}, // hs_6_0 + {198145, 47}, // hs_6_1 + {198146, 48}, // hs_6_2 + {198147, 49}, // hs_6_3 + {198148, 50}, // hs_6_4 + {198149, 51}, // hs_6_5 + {198150, 52}, // hs_6_6 + {198151, 53}, // hs_6_7 + {198152, 54}, // hs_6_8 + {198153, 55}, // hs_6_9 + {263168, 56}, // ds_4_0 + {263169, 57}, // ds_4_1 + {263424, 58}, // ds_5_0 + {263425, 59}, // ds_5_1 + {263680, 60}, // ds_6_0 + {263681, 61}, // ds_6_1 + {263682, 62}, // ds_6_2 + {263683, 63}, // ds_6_3 + {263684, 64}, // ds_6_4 + {263685, 65}, // ds_6_5 + {263686, 66}, // ds_6_6 + {263687, 67}, // ds_6_7 + {263688, 68}, // ds_6_8 + {263689, 69}, // ds_6_9 + {328704, 70}, // cs_4_0 + {328705, 71}, // cs_4_1 + {328960, 72}, // cs_5_0 + {328961, 73}, // cs_5_1 + {329216, 74}, // cs_6_0 + {329217, 75}, // cs_6_1 + {329218, 76}, // cs_6_2 + {329219, 77}, // cs_6_3 + {329220, 78}, // cs_6_4 + {329221, 79}, // cs_6_5 + {329222, 80}, // cs_6_6 + {329223, 81}, // cs_6_7 + {329224, 82}, // cs_6_8 + {329225, 83}, // cs_6_9 + {394241, 84}, // lib_4_1 + {394497, 85}, // lib_5_1 + {394753, 86}, // lib_6_1 + {394754, 87}, // lib_6_2 + {394755, 88}, // lib_6_3 + {394756, 89}, // lib_6_4 + {394757, 90}, // lib_6_5 + {394758, 91}, // lib_6_6 + {394759, 92}, // lib_6_7 + {394760, 93}, // lib_6_8 + {394761, 94}, // lib_6_9 // lib_6_x is for offline linking only, and relaxes restrictions - {394767, 102}, // lib_6_x - {853509, 103}, // ms_6_5 - {853510, 104}, // ms_6_6 - {853511, 105}, // ms_6_7 - {853512, 106}, // ms_6_8 - {853513, 107}, // ms_6_9 - {853514, 108}, // ms_6_10 - {919045, 109}, // as_6_5 - {919046, 110}, // as_6_6 - {919047, 111}, // as_6_7 - {919048, 112}, // as_6_8 - {919049, 113}, // as_6_9 - {919050, 114}, // as_6_10 + {394767, 95}, // lib_6_x + {853509, 96}, // ms_6_5 + {853510, 97}, // ms_6_6 + {853511, 98}, // ms_6_7 + {853512, 99}, // ms_6_8 + {853513, 100}, // ms_6_9 + {919045, 101}, // as_6_5 + {919046, 102}, // as_6_6 + {919047, 103}, // as_6_7 + {919048, 104}, // as_6_8 + {919049, 105}, // as_6_9 }; unsigned hash = (unsigned)Kind << 16 | Major << 8 | Minor; auto pred = [](const std::pair &elem, unsigned val) { @@ -338,9 +328,6 @@ void ShaderModel::GetDxilVersion(unsigned &DxilMajor, case 9: DxilMinor = 9; break; - case 10: - DxilMinor = 10; - break; case kOfflineMinor: // Always update this to highest dxil version DxilMinor = DXIL::kDxilMinor; break; @@ -391,9 +378,6 @@ void ShaderModel::GetMinValidatorVersion(unsigned &ValMajor, case 9: ValMinor = 9; break; - case 10: - ValMinor = 10; - break; // VALRULE-TEXT:END case kOfflineMinor: ValMajor = 0; @@ -535,7 +519,6 @@ const ShaderModel ShaderModel::ms_ShaderModels[kNumShaderModels] = { SM(Kind::Pixel, 6, 7, "ps_6_7", 32, 8, true, true, UINT_MAX), SM(Kind::Pixel, 6, 8, "ps_6_8", 32, 8, true, true, UINT_MAX), SM(Kind::Pixel, 6, 9, "ps_6_9", 32, 8, true, true, UINT_MAX), - SM(Kind::Pixel, 6, 10, "ps_6_10", 32, 8, true, true, UINT_MAX), SM(Kind::Vertex, 4, 0, "vs_4_0", 16, 16, false, false, 0), SM(Kind::Vertex, 4, 1, "vs_4_1", 32, 32, false, false, 0), SM(Kind::Vertex, 5, 0, "vs_5_0", 32, 32, true, true, 64), @@ -550,7 +533,6 @@ const ShaderModel ShaderModel::ms_ShaderModels[kNumShaderModels] = { SM(Kind::Vertex, 6, 7, "vs_6_7", 32, 32, true, true, UINT_MAX), SM(Kind::Vertex, 6, 8, "vs_6_8", 32, 32, true, true, UINT_MAX), SM(Kind::Vertex, 6, 9, "vs_6_9", 32, 32, true, true, UINT_MAX), - SM(Kind::Vertex, 6, 10, "vs_6_10", 32, 32, true, true, UINT_MAX), SM(Kind::Geometry, 4, 0, "gs_4_0", 16, 32, false, false, 0), SM(Kind::Geometry, 4, 1, "gs_4_1", 32, 32, false, false, 0), SM(Kind::Geometry, 5, 0, "gs_5_0", 32, 32, true, true, 64), @@ -565,7 +547,6 @@ const ShaderModel ShaderModel::ms_ShaderModels[kNumShaderModels] = { SM(Kind::Geometry, 6, 7, "gs_6_7", 32, 32, true, true, UINT_MAX), SM(Kind::Geometry, 6, 8, "gs_6_8", 32, 32, true, true, UINT_MAX), SM(Kind::Geometry, 6, 9, "gs_6_9", 32, 32, true, true, UINT_MAX), - SM(Kind::Geometry, 6, 10, "gs_6_10", 32, 32, true, true, UINT_MAX), SM(Kind::Hull, 4, 0, "hs_4_0", 32, 32, false, false, 0), SM(Kind::Hull, 4, 1, "hs_4_1", 32, 32, false, false, 0), SM(Kind::Hull, 5, 0, "hs_5_0", 32, 32, true, true, 64), @@ -580,7 +561,6 @@ const ShaderModel ShaderModel::ms_ShaderModels[kNumShaderModels] = { SM(Kind::Hull, 6, 7, "hs_6_7", 32, 32, true, true, UINT_MAX), SM(Kind::Hull, 6, 8, "hs_6_8", 32, 32, true, true, UINT_MAX), SM(Kind::Hull, 6, 9, "hs_6_9", 32, 32, true, true, UINT_MAX), - SM(Kind::Hull, 6, 10, "hs_6_10", 32, 32, true, true, UINT_MAX), SM(Kind::Domain, 4, 0, "ds_4_0", 32, 32, false, false, 0), SM(Kind::Domain, 4, 1, "ds_4_1", 32, 32, false, false, 0), SM(Kind::Domain, 5, 0, "ds_5_0", 32, 32, true, true, 64), @@ -595,7 +575,6 @@ const ShaderModel ShaderModel::ms_ShaderModels[kNumShaderModels] = { SM(Kind::Domain, 6, 7, "ds_6_7", 32, 32, true, true, UINT_MAX), SM(Kind::Domain, 6, 8, "ds_6_8", 32, 32, true, true, UINT_MAX), SM(Kind::Domain, 6, 9, "ds_6_9", 32, 32, true, true, UINT_MAX), - SM(Kind::Domain, 6, 10, "ds_6_10", 32, 32, true, true, UINT_MAX), SM(Kind::Compute, 4, 0, "cs_4_0", 0, 0, false, false, 0), SM(Kind::Compute, 4, 1, "cs_4_1", 0, 0, false, false, 0), SM(Kind::Compute, 5, 0, "cs_5_0", 0, 0, true, true, 64), @@ -610,7 +589,6 @@ const ShaderModel ShaderModel::ms_ShaderModels[kNumShaderModels] = { SM(Kind::Compute, 6, 7, "cs_6_7", 0, 0, true, true, UINT_MAX), SM(Kind::Compute, 6, 8, "cs_6_8", 0, 0, true, true, UINT_MAX), SM(Kind::Compute, 6, 9, "cs_6_9", 0, 0, true, true, UINT_MAX), - SM(Kind::Compute, 6, 10, "cs_6_10", 0, 0, true, true, UINT_MAX), SM(Kind::Library, 4, 1, "lib_4_1", 0, 0, false, false, 0), SM(Kind::Library, 5, 1, "lib_5_1", 0, 0, true, true, 64), SM(Kind::Library, 6, 1, "lib_6_1", 0, 0, true, true, UINT_MAX), @@ -622,7 +600,6 @@ const ShaderModel ShaderModel::ms_ShaderModels[kNumShaderModels] = { SM(Kind::Library, 6, 7, "lib_6_7", 0, 0, true, true, UINT_MAX), SM(Kind::Library, 6, 8, "lib_6_8", 0, 0, true, true, UINT_MAX), SM(Kind::Library, 6, 9, "lib_6_9", 0, 0, true, true, UINT_MAX), - SM(Kind::Library, 6, 10, "lib_6_10", 0, 0, true, true, UINT_MAX), // lib_6_x is for offline linking only, and relaxes restrictions SM(Kind::Library, 6, kOfflineMinor, "lib_6_x", 32, 32, true, true, UINT_MAX), @@ -631,13 +608,11 @@ const ShaderModel ShaderModel::ms_ShaderModels[kNumShaderModels] = { SM(Kind::Mesh, 6, 7, "ms_6_7", 0, 0, true, true, UINT_MAX), SM(Kind::Mesh, 6, 8, "ms_6_8", 0, 0, true, true, UINT_MAX), SM(Kind::Mesh, 6, 9, "ms_6_9", 0, 0, true, true, UINT_MAX), - SM(Kind::Mesh, 6, 10, "ms_6_10", 0, 0, true, true, UINT_MAX), SM(Kind::Amplification, 6, 5, "as_6_5", 0, 0, true, true, UINT_MAX), SM(Kind::Amplification, 6, 6, "as_6_6", 0, 0, true, true, UINT_MAX), SM(Kind::Amplification, 6, 7, "as_6_7", 0, 0, true, true, UINT_MAX), SM(Kind::Amplification, 6, 8, "as_6_8", 0, 0, true, true, UINT_MAX), SM(Kind::Amplification, 6, 9, "as_6_9", 0, 0, true, true, UINT_MAX), - SM(Kind::Amplification, 6, 10, "as_6_10", 0, 0, true, true, UINT_MAX), // Values before Invalid must remain sorted by Kind, then Major, then Minor. SM(Kind::Invalid, 0, 0, "invalid", 0, 0, false, false, 0), // VALRULE-TEXT:END diff --git a/utils/hct/hctdb_instrhelp.py b/utils/hct/hctdb_instrhelp.py index ea2be77251..2afcff03fc 100644 --- a/utils/hct/hctdb_instrhelp.py +++ b/utils/hct/hctdb_instrhelp.py @@ -1678,7 +1678,7 @@ def get_extended_table_opcode_enum_decls(): # since there can be pre-release versions that are higher # than the last released version highest_major = 6 -highest_minor = 10 +highest_minor = 9 highest_shader_models = {4: 1, 5: 1, 6: highest_minor} # fetch the last released version from latest-released.json From d6b25a9314742086bdf264da03bfcc04aaa0ba8f Mon Sep 17 00:00:00 2001 From: Alex Sepkowski <5620315+alsepkow@users.noreply.github.com> Date: Thu, 22 Jan 2026 16:07:00 -0800 Subject: [PATCH 2/4] Require DXIL 1.10 for PSV tests --- tools/clang/unittests/HLSL/ValidationTest.cpp | 22 +++++++++---------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/tools/clang/unittests/HLSL/ValidationTest.cpp b/tools/clang/unittests/HLSL/ValidationTest.cpp index b1b79bbae9..345825d832 100644 --- a/tools/clang/unittests/HLSL/ValidationTest.cpp +++ b/tools/clang/unittests/HLSL/ValidationTest.cpp @@ -5553,7 +5553,7 @@ SimplePSV::SimplePSV(const DxilPartHeader *pPSVPart) { TEST_F(ValidationTest, PSVContentValidationVS) { if (!m_ver.m_InternalValidator) - if (m_ver.SkipDxilVersion(1, 8)) + if (m_ver.SkipDxilVersion(1, 10)) return; CComPtr pProgram; @@ -5709,7 +5709,7 @@ TEST_F(ValidationTest, PSVContentValidationVS) { TEST_F(ValidationTest, PSVContentValidationHS) { if (!m_ver.m_InternalValidator) - if (m_ver.SkipDxilVersion(1, 8)) + if (m_ver.SkipDxilVersion(1, 10)) return; CComPtr pProgram; @@ -5859,7 +5859,7 @@ TEST_F(ValidationTest, PSVContentValidationHS) { TEST_F(ValidationTest, PSVContentValidationDS) { if (!m_ver.m_InternalValidator) - if (m_ver.SkipDxilVersion(1, 8)) + if (m_ver.SkipDxilVersion(1, 10)) return; CComPtr pProgram; @@ -6016,7 +6016,7 @@ TEST_F(ValidationTest, PSVContentValidationDS) { TEST_F(ValidationTest, PSVContentValidationGS) { if (!m_ver.m_InternalValidator) - if (m_ver.SkipDxilVersion(1, 8)) + if (m_ver.SkipDxilVersion(1, 10)) return; CComPtr pProgram; @@ -6104,7 +6104,7 @@ TEST_F(ValidationTest, PSVContentValidationGS) { TEST_F(ValidationTest, PSVContentValidationPS) { if (!m_ver.m_InternalValidator) - if (m_ver.SkipDxilVersion(1, 8)) + if (m_ver.SkipDxilVersion(1, 10)) return; CComPtr pProgram; @@ -6189,7 +6189,7 @@ TEST_F(ValidationTest, PSVContentValidationPS) { TEST_F(ValidationTest, PSVContentValidationCS) { if (!m_ver.m_InternalValidator) - if (m_ver.SkipDxilVersion(1, 8)) + if (m_ver.SkipDxilVersion(1, 10)) return; CComPtr pProgram; @@ -6271,7 +6271,7 @@ TEST_F(ValidationTest, PSVContentValidationCS) { TEST_F(ValidationTest, PSVContentValidationMS) { if (!m_ver.m_InternalValidator) - if (m_ver.SkipDxilVersion(1, 8)) + if (m_ver.SkipDxilVersion(1, 10)) return; CComPtr pProgram; @@ -6338,7 +6338,7 @@ TEST_F(ValidationTest, PSVContentValidationMS) { TEST_F(ValidationTest, PSVContentValidationAS) { if (!m_ver.m_InternalValidator) - if (m_ver.SkipDxilVersion(1, 8)) + if (m_ver.SkipDxilVersion(1, 10)) return; CComPtr pProgram; @@ -6440,7 +6440,7 @@ struct SimpleContainer { TEST_F(ValidationTest, WrongPSVSize) { if (!m_ver.m_InternalValidator) - if (m_ver.SkipDxilVersion(1, 8)) + if (m_ver.SkipDxilVersion(1, 10)) return; CComPtr pProgram; @@ -6529,7 +6529,7 @@ TEST_F(ValidationTest, WrongPSVSize) { TEST_F(ValidationTest, WrongPSVSizeOnZeros) { if (!m_ver.m_InternalValidator) - if (m_ver.SkipDxilVersion(1, 8)) + if (m_ver.SkipDxilVersion(1, 10)) return; CComPtr pProgram; @@ -6625,7 +6625,7 @@ TEST_F(ValidationTest, WrongPSVSizeOnZeros) { TEST_F(ValidationTest, WrongPSVVersion) { if (!m_ver.m_InternalValidator) - if (m_ver.SkipDxilVersion(1, 8)) + if (m_ver.SkipDxilVersion(1, 10)) return; CComPtr pProgram60; From 792841bdda32cb92944a3fc5fc3000cc145e84b7 Mon Sep 17 00:00:00 2001 From: Alex Sepkowski <5620315+alsepkow@users.noreply.github.com> Date: Thu, 22 Jan 2026 16:28:05 -0800 Subject: [PATCH 3/4] Fix skip logic --- tools/clang/unittests/HLSL/ValidationTest.cpp | 60 ++++++++----------- 1 file changed, 24 insertions(+), 36 deletions(-) diff --git a/tools/clang/unittests/HLSL/ValidationTest.cpp b/tools/clang/unittests/HLSL/ValidationTest.cpp index 345825d832..1e3bd494c8 100644 --- a/tools/clang/unittests/HLSL/ValidationTest.cpp +++ b/tools/clang/unittests/HLSL/ValidationTest.cpp @@ -4883,9 +4883,8 @@ TEST_F(ValidationTest, CacheInitWithLowPrec) { } TEST_F(ValidationTest, PSVStringTableReorder) { - if (!m_ver.m_InternalValidator) - if (m_ver.SkipDxilVersion(1, 8)) - return; + if (m_ver.SkipDxilVersion(1, 10)) + return; CComPtr pProgram; CompileSource("float4 main(float a:A, float b:B) : SV_Target { return 1; }", @@ -5076,9 +5075,8 @@ class SemanticIndexRotator { }; TEST_F(ValidationTest, PSVSemanticIndexTableReorder) { - if (!m_ver.m_InternalValidator) - if (m_ver.SkipDxilVersion(1, 8)) - return; + if (m_ver.SkipDxilVersion(1, 10)) + return; CComPtr pProgram; CompileFile(L"..\\DXILValidation\\hs_signatures.hlsl", "hs_6_0", &pProgram); @@ -5552,9 +5550,8 @@ SimplePSV::SimplePSV(const DxilPartHeader *pPSVPart) { } TEST_F(ValidationTest, PSVContentValidationVS) { - if (!m_ver.m_InternalValidator) - if (m_ver.SkipDxilVersion(1, 10)) - return; + if (m_ver.SkipDxilVersion(1, 10)) + return; CComPtr pProgram; CompileFile(L"..\\DXC\\dumpPSV_VS.hlsl", "vs_6_8", &pProgram); @@ -5708,9 +5705,8 @@ TEST_F(ValidationTest, PSVContentValidationVS) { } TEST_F(ValidationTest, PSVContentValidationHS) { - if (!m_ver.m_InternalValidator) - if (m_ver.SkipDxilVersion(1, 10)) - return; + if (m_ver.SkipDxilVersion(1, 10)) + return; CComPtr pProgram; CompileFile(L"..\\DXC\\dumpPSV_HS.hlsl", "hs_6_8", &pProgram); @@ -5858,9 +5854,8 @@ TEST_F(ValidationTest, PSVContentValidationHS) { } TEST_F(ValidationTest, PSVContentValidationDS) { - if (!m_ver.m_InternalValidator) - if (m_ver.SkipDxilVersion(1, 10)) - return; + if (m_ver.SkipDxilVersion(1, 10)) + return; CComPtr pProgram; CompileFile(L"..\\DXC\\dumpPSV_DS.hlsl", "ds_6_8", &pProgram); @@ -6015,9 +6010,8 @@ TEST_F(ValidationTest, PSVContentValidationDS) { } TEST_F(ValidationTest, PSVContentValidationGS) { - if (!m_ver.m_InternalValidator) - if (m_ver.SkipDxilVersion(1, 10)) - return; + if (m_ver.SkipDxilVersion(1, 10)) + return; CComPtr pProgram; CompileFile(L"..\\DXC\\dumpPSV_GS.hlsl", "gs_6_8", &pProgram); @@ -6103,9 +6097,8 @@ TEST_F(ValidationTest, PSVContentValidationGS) { } TEST_F(ValidationTest, PSVContentValidationPS) { - if (!m_ver.m_InternalValidator) - if (m_ver.SkipDxilVersion(1, 10)) - return; + if (m_ver.SkipDxilVersion(1, 10)) + return; CComPtr pProgram; CompileFile(L"..\\DXC\\dumpPSV_PS.hlsl", "ps_6_8", &pProgram); @@ -6188,9 +6181,8 @@ TEST_F(ValidationTest, PSVContentValidationPS) { } TEST_F(ValidationTest, PSVContentValidationCS) { - if (!m_ver.m_InternalValidator) - if (m_ver.SkipDxilVersion(1, 10)) - return; + if (m_ver.SkipDxilVersion(1, 10)) + return; CComPtr pProgram; CompileFile(L"..\\DXC\\dumpPSV_CS.hlsl", "cs_6_8", &pProgram); @@ -6270,9 +6262,8 @@ TEST_F(ValidationTest, PSVContentValidationCS) { } TEST_F(ValidationTest, PSVContentValidationMS) { - if (!m_ver.m_InternalValidator) - if (m_ver.SkipDxilVersion(1, 10)) - return; + if (m_ver.SkipDxilVersion(1, 10)) + return; CComPtr pProgram; CompileFile(L"..\\DXC\\dumpPSV_MS.hlsl", "ms_6_8", &pProgram); @@ -6337,9 +6328,8 @@ TEST_F(ValidationTest, PSVContentValidationMS) { } TEST_F(ValidationTest, PSVContentValidationAS) { - if (!m_ver.m_InternalValidator) - if (m_ver.SkipDxilVersion(1, 10)) - return; + if (m_ver.SkipDxilVersion(1, 10)) + return; CComPtr pProgram; CompileFile(L"..\\DXC\\dumpPSV_AS.hlsl", "as_6_8", &pProgram); @@ -6439,9 +6429,8 @@ struct SimpleContainer { }; TEST_F(ValidationTest, WrongPSVSize) { - if (!m_ver.m_InternalValidator) - if (m_ver.SkipDxilVersion(1, 10)) - return; + if (m_ver.SkipDxilVersion(1, 10)) + return; CComPtr pProgram; CompileFile(L"..\\DXC\\dumpPSV_AS.hlsl", "as_6_8", &pProgram); @@ -6528,9 +6517,8 @@ TEST_F(ValidationTest, WrongPSVSize) { } TEST_F(ValidationTest, WrongPSVSizeOnZeros) { - if (!m_ver.m_InternalValidator) - if (m_ver.SkipDxilVersion(1, 10)) - return; + if (m_ver.SkipDxilVersion(1, 10)) + return; CComPtr pProgram; CompileFile(L"..\\DXC\\dumpPSV_PS.hlsl", "ps_6_8", &pProgram); From fd08fc4736b02fb3c21a75653dc78e6501710b61 Mon Sep 17 00:00:00 2001 From: Alex Sepkowski <5620315+alsepkow@users.noreply.github.com> Date: Thu, 22 Jan 2026 16:34:31 -0800 Subject: [PATCH 4/4] Missed one --- tools/clang/unittests/HLSL/ValidationTest.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/tools/clang/unittests/HLSL/ValidationTest.cpp b/tools/clang/unittests/HLSL/ValidationTest.cpp index 1e3bd494c8..796f017f09 100644 --- a/tools/clang/unittests/HLSL/ValidationTest.cpp +++ b/tools/clang/unittests/HLSL/ValidationTest.cpp @@ -6612,9 +6612,8 @@ TEST_F(ValidationTest, WrongPSVSizeOnZeros) { } TEST_F(ValidationTest, WrongPSVVersion) { - if (!m_ver.m_InternalValidator) - if (m_ver.SkipDxilVersion(1, 10)) - return; + if (m_ver.SkipDxilVersion(1, 10)) + return; CComPtr pProgram60; std::vector args;