Skip to content

Commit 67628e5

Browse files
Add checks to env destruction
Signed-off-by: Mikołaj Komar <[email protected]>
1 parent 96a5dbc commit 67628e5

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

source/benchmarks/graph_api_benchmark/implementations/l0/mutate_graph_impl_l0.cpp

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -164,16 +164,16 @@ TestResult initEnv(TestEnv &env, const MutateGraphArguments &arguments) {
164164
}
165165

166166
TestResult destroyEnv(TestEnv &env) {
167-
zeKernelDestroy(env.kernelSum);
168-
zeKernelDestroy(env.kernelMul);
169-
zeModuleDestroy(env.moduleSum);
170-
zeModuleDestroy(env.moduleMul);
171-
zeCommandListDestroy(env.immCmdList);
167+
ASSERT_ZE_RESULT_SUCCESS(zeKernelDestroy(env.kernelSum));
168+
ASSERT_ZE_RESULT_SUCCESS(zeKernelDestroy(env.kernelMul));
169+
ASSERT_ZE_RESULT_SUCCESS(zeModuleDestroy(env.moduleSum));
170+
ASSERT_ZE_RESULT_SUCCESS(zeModuleDestroy(env.moduleMul));
171+
ASSERT_ZE_RESULT_SUCCESS(zeCommandListDestroy(env.immCmdList));
172172
if (env.zePool != nullptr) {
173173
for (auto zeEvent : env.zeEvents) {
174-
zeEventDestroy(zeEvent);
174+
ASSERT_ZE_RESULT_SUCCESS(zeEventDestroy(zeEvent));
175175
}
176-
zeEventPoolDestroy(env.zePool);
176+
ASSERT_ZE_RESULT_SUCCESS(zeEventPoolDestroy(env.zePool));
177177
}
178178
return TestResult::Success;
179179
}

0 commit comments

Comments
 (0)