mirror of
https://github.com/KhronosGroup/SPIRV-Tools
synced 2024-12-12 11:40:14 +00:00
Vulkan 1.4 support (#5899)
* Add a Vulkan 1.4 environment * Fix test: Vulkan 1.3 accepts SPIR-V 1.6 * Fix comments about Vulkan 1.4 * Add test cases for Vulkan 1.4, optimizer ir_context tests --------- Co-authored-by: Faith Ekstrand <faith.ekstrand@collabora.com>
This commit is contained in:
parent
7d5bc35197
commit
3fb52548bc
@ -540,6 +540,7 @@ SPIRV_TOOLS_EXPORT const char* spvSoftwareVersionDetailsString(void);
|
||||
// SPV_ENV_VULKAN_1_1_SPIRV_1_4 -> SPIR-V 1.4
|
||||
// SPV_ENV_VULKAN_1_2 -> SPIR-V 1.5
|
||||
// SPV_ENV_VULKAN_1_3 -> SPIR-V 1.6
|
||||
// SPV_ENV_VULKAN_1_4 -> SPIR-V 1.6
|
||||
// Consult the description of API entry points for specific rules.
|
||||
typedef enum {
|
||||
SPV_ENV_UNIVERSAL_1_0, // SPIR-V 1.0 latest revision, no other restrictions.
|
||||
@ -577,6 +578,7 @@ typedef enum {
|
||||
|
||||
SPV_ENV_UNIVERSAL_1_6, // SPIR-V 1.6 latest revision, no other restrictions.
|
||||
SPV_ENV_VULKAN_1_3, // Vulkan 1.3 latest revision.
|
||||
SPV_ENV_VULKAN_1_4, // Vulkan 1.4 latest revision.
|
||||
|
||||
SPV_ENV_MAX // Keep this as the last enum value.
|
||||
} spv_target_env;
|
||||
|
@ -102,6 +102,7 @@ spv_result_t spvExtInstTableGet(spv_ext_inst_table* pExtInstTable,
|
||||
case SPV_ENV_VULKAN_1_2:
|
||||
case SPV_ENV_UNIVERSAL_1_6:
|
||||
case SPV_ENV_VULKAN_1_3:
|
||||
case SPV_ENV_VULKAN_1_4:
|
||||
*pExtInstTable = &kTable_1_0;
|
||||
return SPV_SUCCESS;
|
||||
default:
|
||||
|
@ -79,6 +79,8 @@ const char* spvTargetEnvDescription(spv_target_env env) {
|
||||
return "SPIR-V 1.6";
|
||||
case SPV_ENV_VULKAN_1_3:
|
||||
return "SPIR-V 1.6 (under Vulkan 1.3 semantics)";
|
||||
case SPV_ENV_VULKAN_1_4:
|
||||
return "SPIR-V 1.6 (under Vulkan 1.4 semantics)";
|
||||
case SPV_ENV_MAX:
|
||||
assert(false && "Invalid target environment value.");
|
||||
break;
|
||||
@ -122,6 +124,7 @@ uint32_t spvVersionForTargetEnv(spv_target_env env) {
|
||||
return SPV_SPIRV_VERSION_WORD(1, 5);
|
||||
case SPV_ENV_UNIVERSAL_1_6:
|
||||
case SPV_ENV_VULKAN_1_3:
|
||||
case SPV_ENV_VULKAN_1_4:
|
||||
return SPV_SPIRV_VERSION_WORD(1, 6);
|
||||
case SPV_ENV_MAX:
|
||||
assert(false && "Invalid target environment value.");
|
||||
@ -147,6 +150,7 @@ inline constexpr std::pair<const char*, spv_target_env> spvTargetEnvNameMap[] =
|
||||
{"vulkan1.1", SPV_ENV_VULKAN_1_1},
|
||||
{"vulkan1.2", SPV_ENV_VULKAN_1_2},
|
||||
{"vulkan1.3", SPV_ENV_VULKAN_1_3},
|
||||
{"vulkan1.4", SPV_ENV_VULKAN_1_4},
|
||||
{"spv1.0", SPV_ENV_UNIVERSAL_1_0},
|
||||
{"spv1.1", SPV_ENV_UNIVERSAL_1_1},
|
||||
{"spv1.2", SPV_ENV_UNIVERSAL_1_2},
|
||||
@ -254,7 +258,8 @@ static const VulkanEnv ordered_vulkan_envs[] = {
|
||||
{SPV_ENV_VULKAN_1_1, VULKAN_VER(1, 1), SPIRV_VER(1, 3)},
|
||||
{SPV_ENV_VULKAN_1_1_SPIRV_1_4, VULKAN_VER(1, 1), SPIRV_VER(1, 4)},
|
||||
{SPV_ENV_VULKAN_1_2, VULKAN_VER(1, 2), SPIRV_VER(1, 5)},
|
||||
{SPV_ENV_VULKAN_1_3, VULKAN_VER(1, 3), SPIRV_VER(1, 6)}};
|
||||
{SPV_ENV_VULKAN_1_3, VULKAN_VER(1, 3), SPIRV_VER(1, 6)},
|
||||
{SPV_ENV_VULKAN_1_4, VULKAN_VER(1, 4), SPIRV_VER(1, 6)}};
|
||||
|
||||
bool spvParseVulkanEnv(uint32_t vulkan_ver, uint32_t spirv_ver,
|
||||
spv_target_env* env) {
|
||||
@ -295,6 +300,7 @@ bool spvIsVulkanEnv(spv_target_env env) {
|
||||
case SPV_ENV_VULKAN_1_1_SPIRV_1_4:
|
||||
case SPV_ENV_VULKAN_1_2:
|
||||
case SPV_ENV_VULKAN_1_3:
|
||||
case SPV_ENV_VULKAN_1_4:
|
||||
return true;
|
||||
case SPV_ENV_WEBGPU_0:
|
||||
assert(false && "Deprecated target environment value.");
|
||||
@ -325,6 +331,7 @@ bool spvIsOpenCLEnv(spv_target_env env) {
|
||||
case SPV_ENV_VULKAN_1_2:
|
||||
case SPV_ENV_UNIVERSAL_1_6:
|
||||
case SPV_ENV_VULKAN_1_3:
|
||||
case SPV_ENV_VULKAN_1_4:
|
||||
return false;
|
||||
case SPV_ENV_OPENCL_1_2:
|
||||
case SPV_ENV_OPENCL_EMBEDDED_1_2:
|
||||
@ -367,6 +374,7 @@ bool spvIsOpenGLEnv(spv_target_env env) {
|
||||
case SPV_ENV_VULKAN_1_2:
|
||||
case SPV_ENV_UNIVERSAL_1_6:
|
||||
case SPV_ENV_VULKAN_1_3:
|
||||
case SPV_ENV_VULKAN_1_4:
|
||||
return false;
|
||||
case SPV_ENV_OPENGL_4_0:
|
||||
case SPV_ENV_OPENGL_4_1:
|
||||
@ -406,6 +414,7 @@ bool spvIsValidEnv(spv_target_env env) {
|
||||
case SPV_ENV_VULKAN_1_2:
|
||||
case SPV_ENV_UNIVERSAL_1_6:
|
||||
case SPV_ENV_VULKAN_1_3:
|
||||
case SPV_ENV_VULKAN_1_4:
|
||||
case SPV_ENV_OPENGL_4_0:
|
||||
case SPV_ENV_OPENGL_4_1:
|
||||
case SPV_ENV_OPENGL_4_2:
|
||||
@ -442,7 +451,8 @@ std::string spvLogStringForEnv(spv_target_env env) {
|
||||
case SPV_ENV_VULKAN_1_1:
|
||||
case SPV_ENV_VULKAN_1_1_SPIRV_1_4:
|
||||
case SPV_ENV_VULKAN_1_2:
|
||||
case SPV_ENV_VULKAN_1_3: {
|
||||
case SPV_ENV_VULKAN_1_3:
|
||||
case SPV_ENV_VULKAN_1_4: {
|
||||
return "Vulkan";
|
||||
}
|
||||
case SPV_ENV_UNIVERSAL_1_0:
|
||||
|
@ -43,6 +43,7 @@ spv_context spvContextCreate(spv_target_env env) {
|
||||
case SPV_ENV_VULKAN_1_2:
|
||||
case SPV_ENV_UNIVERSAL_1_6:
|
||||
case SPV_ENV_VULKAN_1_3:
|
||||
case SPV_ENV_VULKAN_1_4:
|
||||
break;
|
||||
default:
|
||||
return nullptr;
|
||||
|
@ -1155,10 +1155,7 @@ struct TargetEnvCompareTestData {
|
||||
|
||||
using TargetEnvCompareTest = ::testing::TestWithParam<TargetEnvCompareTestData>;
|
||||
|
||||
TEST_P(TargetEnvCompareTest, Case) {
|
||||
// If new environments are added, then we must update the list of tests.
|
||||
ASSERT_EQ(SPV_ENV_VULKAN_1_3 + 1, SPV_ENV_MAX);
|
||||
|
||||
TEST_P(TargetEnvCompareTest, IsTargetEnvAtLeast) {
|
||||
const auto& tc = GetParam();
|
||||
|
||||
std::unique_ptr<Module> module(new Module());
|
||||
@ -1422,6 +1419,8 @@ TEST_F(IRContextTest, RemovesMultipleCapabilities) {
|
||||
1);
|
||||
}
|
||||
|
||||
// If new environments are added, then we must update the list of tests.
|
||||
static_assert(SPV_ENV_VULKAN_1_4 + 1 == SPV_ENV_MAX);
|
||||
INSTANTIATE_TEST_SUITE_P(
|
||||
TestCase, TargetEnvCompareTest,
|
||||
::testing::Values(
|
||||
@ -1464,6 +1463,7 @@ INSTANTIATE_TEST_SUITE_P(
|
||||
TargetEnvCompareTestData{SPV_ENV_VULKAN_1_1, SPV_ENV_UNIVERSAL_1_1},
|
||||
TargetEnvCompareTestData{SPV_ENV_VULKAN_1_1, SPV_ENV_UNIVERSAL_1_2},
|
||||
TargetEnvCompareTestData{SPV_ENV_VULKAN_1_1, SPV_ENV_UNIVERSAL_1_3},
|
||||
TargetEnvCompareTestData{SPV_ENV_VULKAN_1_1, SPV_ENV_VULKAN_1_0},
|
||||
TargetEnvCompareTestData{SPV_ENV_UNIVERSAL_1_4, SPV_ENV_VULKAN_1_1},
|
||||
TargetEnvCompareTestData{SPV_ENV_UNIVERSAL_1_5, SPV_ENV_VULKAN_1_1},
|
||||
TargetEnvCompareTestData{SPV_ENV_UNIVERSAL_1_6, SPV_ENV_VULKAN_1_1},
|
||||
@ -1473,6 +1473,7 @@ INSTANTIATE_TEST_SUITE_P(
|
||||
TargetEnvCompareTestData{SPV_ENV_VULKAN_1_2, SPV_ENV_UNIVERSAL_1_3},
|
||||
TargetEnvCompareTestData{SPV_ENV_VULKAN_1_2, SPV_ENV_UNIVERSAL_1_4},
|
||||
TargetEnvCompareTestData{SPV_ENV_VULKAN_1_2, SPV_ENV_UNIVERSAL_1_5},
|
||||
TargetEnvCompareTestData{SPV_ENV_VULKAN_1_2, SPV_ENV_VULKAN_1_1},
|
||||
TargetEnvCompareTestData{SPV_ENV_UNIVERSAL_1_6, SPV_ENV_VULKAN_1_2},
|
||||
TargetEnvCompareTestData{SPV_ENV_VULKAN_1_3, SPV_ENV_UNIVERSAL_1_0},
|
||||
TargetEnvCompareTestData{SPV_ENV_VULKAN_1_3, SPV_ENV_UNIVERSAL_1_1},
|
||||
@ -1480,7 +1481,16 @@ INSTANTIATE_TEST_SUITE_P(
|
||||
TargetEnvCompareTestData{SPV_ENV_VULKAN_1_3, SPV_ENV_UNIVERSAL_1_3},
|
||||
TargetEnvCompareTestData{SPV_ENV_VULKAN_1_3, SPV_ENV_UNIVERSAL_1_4},
|
||||
TargetEnvCompareTestData{SPV_ENV_VULKAN_1_3, SPV_ENV_UNIVERSAL_1_5},
|
||||
TargetEnvCompareTestData{SPV_ENV_VULKAN_1_3, SPV_ENV_UNIVERSAL_1_6}));
|
||||
TargetEnvCompareTestData{SPV_ENV_VULKAN_1_3, SPV_ENV_UNIVERSAL_1_6},
|
||||
TargetEnvCompareTestData{SPV_ENV_VULKAN_1_3, SPV_ENV_VULKAN_1_2},
|
||||
TargetEnvCompareTestData{SPV_ENV_VULKAN_1_4, SPV_ENV_UNIVERSAL_1_0},
|
||||
TargetEnvCompareTestData{SPV_ENV_VULKAN_1_4, SPV_ENV_UNIVERSAL_1_1},
|
||||
TargetEnvCompareTestData{SPV_ENV_VULKAN_1_4, SPV_ENV_UNIVERSAL_1_2},
|
||||
TargetEnvCompareTestData{SPV_ENV_VULKAN_1_4, SPV_ENV_UNIVERSAL_1_3},
|
||||
TargetEnvCompareTestData{SPV_ENV_VULKAN_1_4, SPV_ENV_UNIVERSAL_1_4},
|
||||
TargetEnvCompareTestData{SPV_ENV_VULKAN_1_4, SPV_ENV_UNIVERSAL_1_5},
|
||||
TargetEnvCompareTestData{SPV_ENV_VULKAN_1_4, SPV_ENV_UNIVERSAL_1_6},
|
||||
TargetEnvCompareTestData{SPV_ENV_VULKAN_1_4, SPV_ENV_VULKAN_1_3}));
|
||||
|
||||
} // namespace
|
||||
} // namespace opt
|
||||
|
@ -79,6 +79,7 @@ std::string version(spv_target_env env) {
|
||||
return "1.5";
|
||||
case SPV_ENV_UNIVERSAL_1_6:
|
||||
case SPV_ENV_VULKAN_1_3:
|
||||
case SPV_ENV_VULKAN_1_4:
|
||||
return "1.6";
|
||||
default:
|
||||
return "0";
|
||||
@ -117,6 +118,7 @@ INSTANTIATE_TEST_SUITE_P(Universal, ValidateVersion,
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_0, SPV_ENV_VULKAN_1_1_SPIRV_1_4,vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_0, SPV_ENV_VULKAN_1_2, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_0, SPV_ENV_VULKAN_1_3, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_0, SPV_ENV_VULKAN_1_4, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_0, SPV_ENV_OPENGL_4_0, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_0, SPV_ENV_OPENGL_4_1, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_0, SPV_ENV_OPENGL_4_2, vulkan_spirv, true),
|
||||
@ -135,6 +137,7 @@ INSTANTIATE_TEST_SUITE_P(Universal, ValidateVersion,
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_1, SPV_ENV_VULKAN_1_1_SPIRV_1_4, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_1, SPV_ENV_VULKAN_1_2, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_1, SPV_ENV_VULKAN_1_3, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_1, SPV_ENV_VULKAN_1_4, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_1, SPV_ENV_OPENGL_4_0, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_1, SPV_ENV_OPENGL_4_1, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_1, SPV_ENV_OPENGL_4_2, vulkan_spirv, false),
|
||||
@ -153,6 +156,7 @@ INSTANTIATE_TEST_SUITE_P(Universal, ValidateVersion,
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_2, SPV_ENV_VULKAN_1_1_SPIRV_1_4, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_2, SPV_ENV_VULKAN_1_2, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_2, SPV_ENV_VULKAN_1_3, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_2, SPV_ENV_VULKAN_1_4, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_2, SPV_ENV_OPENGL_4_0, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_2, SPV_ENV_OPENGL_4_1, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_2, SPV_ENV_OPENGL_4_2, vulkan_spirv, false),
|
||||
@ -171,6 +175,7 @@ INSTANTIATE_TEST_SUITE_P(Universal, ValidateVersion,
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_3, SPV_ENV_VULKAN_1_1_SPIRV_1_4, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_3, SPV_ENV_VULKAN_1_2, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_3, SPV_ENV_VULKAN_1_3, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_3, SPV_ENV_VULKAN_1_4, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_3, SPV_ENV_OPENGL_4_0, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_3, SPV_ENV_OPENGL_4_1, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_3, SPV_ENV_OPENGL_4_2, vulkan_spirv, false),
|
||||
@ -189,6 +194,7 @@ INSTANTIATE_TEST_SUITE_P(Universal, ValidateVersion,
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_4, SPV_ENV_VULKAN_1_1_SPIRV_1_4, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_4, SPV_ENV_VULKAN_1_2, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_4, SPV_ENV_VULKAN_1_3, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_4, SPV_ENV_VULKAN_1_4, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_4, SPV_ENV_OPENGL_4_0, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_4, SPV_ENV_OPENGL_4_1, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_4, SPV_ENV_OPENGL_4_2, vulkan_spirv, false),
|
||||
@ -207,6 +213,7 @@ INSTANTIATE_TEST_SUITE_P(Universal, ValidateVersion,
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_5, SPV_ENV_VULKAN_1_1_SPIRV_1_4, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_5, SPV_ENV_VULKAN_1_2, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_5, SPV_ENV_VULKAN_1_3, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_5, SPV_ENV_VULKAN_1_4, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_5, SPV_ENV_OPENGL_4_0, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_5, SPV_ENV_OPENGL_4_1, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_5, SPV_ENV_OPENGL_4_2, vulkan_spirv, false),
|
||||
@ -225,6 +232,7 @@ INSTANTIATE_TEST_SUITE_P(Universal, ValidateVersion,
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_6, SPV_ENV_VULKAN_1_1_SPIRV_1_4, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_6, SPV_ENV_VULKAN_1_2, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_6, SPV_ENV_VULKAN_1_3, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_6, SPV_ENV_VULKAN_1_4, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_6, SPV_ENV_OPENGL_4_0, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_6, SPV_ENV_OPENGL_4_1, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_UNIVERSAL_1_6, SPV_ENV_OPENGL_4_2, vulkan_spirv, false),
|
||||
@ -248,6 +256,7 @@ INSTANTIATE_TEST_SUITE_P(Vulkan, ValidateVersion,
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_0, SPV_ENV_VULKAN_1_1_SPIRV_1_4, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_0, SPV_ENV_VULKAN_1_2, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_0, SPV_ENV_VULKAN_1_3, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_0, SPV_ENV_VULKAN_1_4, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_0, SPV_ENV_OPENGL_4_0, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_0, SPV_ENV_OPENGL_4_1, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_0, SPV_ENV_OPENGL_4_2, vulkan_spirv, true),
|
||||
@ -266,6 +275,7 @@ INSTANTIATE_TEST_SUITE_P(Vulkan, ValidateVersion,
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_1, SPV_ENV_VULKAN_1_1_SPIRV_1_4, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_1, SPV_ENV_VULKAN_1_2, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_1, SPV_ENV_VULKAN_1_3, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_1, SPV_ENV_VULKAN_1_4, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_1, SPV_ENV_OPENGL_4_0, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_1, SPV_ENV_OPENGL_4_1, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_1, SPV_ENV_OPENGL_4_2, vulkan_spirv, false),
|
||||
@ -284,6 +294,7 @@ INSTANTIATE_TEST_SUITE_P(Vulkan, ValidateVersion,
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_1_SPIRV_1_4, SPV_ENV_VULKAN_1_1_SPIRV_1_4, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_1_SPIRV_1_4, SPV_ENV_VULKAN_1_2, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_1_SPIRV_1_4, SPV_ENV_VULKAN_1_3, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_1_SPIRV_1_4, SPV_ENV_VULKAN_1_4, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_1_SPIRV_1_4, SPV_ENV_OPENGL_4_0, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_1_SPIRV_1_4, SPV_ENV_OPENGL_4_1, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_1_SPIRV_1_4, SPV_ENV_OPENGL_4_2, vulkan_spirv, false),
|
||||
@ -302,6 +313,7 @@ INSTANTIATE_TEST_SUITE_P(Vulkan, ValidateVersion,
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_2, SPV_ENV_VULKAN_1_1_SPIRV_1_4, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_2, SPV_ENV_VULKAN_1_2, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_2, SPV_ENV_VULKAN_1_3, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_2, SPV_ENV_VULKAN_1_4, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_2, SPV_ENV_OPENGL_4_0, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_2, SPV_ENV_OPENGL_4_1, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_2, SPV_ENV_OPENGL_4_2, vulkan_spirv, false),
|
||||
@ -320,11 +332,33 @@ INSTANTIATE_TEST_SUITE_P(Vulkan, ValidateVersion,
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_3, SPV_ENV_VULKAN_1_1_SPIRV_1_4, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_3, SPV_ENV_VULKAN_1_2, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_3, SPV_ENV_VULKAN_1_3, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_3, SPV_ENV_VULKAN_1_4, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_3, SPV_ENV_OPENGL_4_0, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_3, SPV_ENV_OPENGL_4_1, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_3, SPV_ENV_OPENGL_4_2, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_3, SPV_ENV_OPENGL_4_3, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_3, SPV_ENV_OPENGL_4_5, vulkan_spirv, false)
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_3, SPV_ENV_OPENGL_4_5, vulkan_spirv, false),
|
||||
|
||||
// Assembling for Vulkan 1.4 produces SPIR-V 1.6
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_4, SPV_ENV_UNIVERSAL_1_0, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_4, SPV_ENV_UNIVERSAL_1_1, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_4, SPV_ENV_UNIVERSAL_1_2, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_4, SPV_ENV_UNIVERSAL_1_3, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_4, SPV_ENV_UNIVERSAL_1_4, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_4, SPV_ENV_UNIVERSAL_1_5, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_4, SPV_ENV_UNIVERSAL_1_6, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_4, SPV_ENV_VULKAN_1_0, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_4, SPV_ENV_VULKAN_1_1, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_4, SPV_ENV_VULKAN_1_1_SPIRV_1_4, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_4, SPV_ENV_VULKAN_1_2, vulkan_spirv, false),
|
||||
// Vulkan 1.3 accepts SPIR-V 1.6
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_4, SPV_ENV_VULKAN_1_3, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_4, SPV_ENV_VULKAN_1_4, vulkan_spirv, true),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_4, SPV_ENV_OPENGL_4_0, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_4, SPV_ENV_OPENGL_4_1, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_4, SPV_ENV_OPENGL_4_2, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_4, SPV_ENV_OPENGL_4_3, vulkan_spirv, false),
|
||||
std::make_tuple(SPV_ENV_VULKAN_1_4, SPV_ENV_OPENGL_4_5, vulkan_spirv, false)
|
||||
)
|
||||
);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user