diff --git a/tests/gcn/gcn_test_runner.cpp b/tests/gcn/gcn_test_runner.cpp index 8daf168df..37f4d920e 100644 --- a/tests/gcn/gcn_test_runner.cpp +++ b/tests/gcn/gcn_test_runner.cpp @@ -136,6 +136,11 @@ std::expected Runner::instance() { return g_runner.get(); } +void Runner::DestroyInstance() { + std::lock_guard lock{g_runner_mutex}; + g_runner.reset(); +} + std::expected Runner::initialize() { VULKAN_HPP_DEFAULT_DISPATCHER.init(); @@ -223,6 +228,7 @@ std::expected Runner::initialize() { vk::PhysicalDeviceVulkan12Features v12_feat{ .pNext = &v11_feat, .uniformAndStorageBuffer8BitAccess = VK_TRUE, + .shaderFloat16 = VK_TRUE, .shaderInt8 = VK_TRUE, }; vk::PhysicalDeviceFeatures phys_feat{ diff --git a/tests/gcn/gcn_test_runner.hpp b/tests/gcn/gcn_test_runner.hpp index e15a97f52..eb6643293 100644 --- a/tests/gcn/gcn_test_runner.hpp +++ b/tests/gcn/gcn_test_runner.hpp @@ -42,6 +42,7 @@ struct ErrorInfo { class Runner { public: static std::expected instance(); + static void DestroyInstance(); std::expected run_raw( std::span spirv, diff --git a/tests/gcn/instructions.hpp b/tests/gcn/instructions.hpp index 8620b29fb..379224d50 100644 --- a/tests/gcn/instructions.hpp +++ b/tests/gcn/instructions.hpp @@ -1266,7 +1266,7 @@ private: u64 src2 : 9; u64 omod : 2; u64 neg : 3; - } i; + } i{}; static_assert(sizeof(VOP3Internal) == sizeof(u64)); }; @@ -1345,7 +1345,7 @@ private: u64 src2 : 9; u64 op_sel_hi01 : 2; u64 neg : 3; - } i; + } i{}; static_assert(sizeof(VOP3PInternal) == sizeof(u64)); }; diff --git a/tests/gcn/test_gcn_instructions.cpp b/tests/gcn/test_gcn_instructions.cpp index 03fa8a588..ee29675cf 100644 --- a/tests/gcn/test_gcn_instructions.cpp +++ b/tests/gcn/test_gcn_instructions.cpp @@ -15,6 +15,10 @@ protected: void SetUp() override {} void TearDown() override {} + + static void TearDownTestSuite() { + gcn_test::Runner::DestroyInstance(); + } }; struct F32x2 {