From 80040bce896357fa15b7a6f05a624b9e18ee5821 Mon Sep 17 00:00:00 2001 From: Anthony Barbier Date: Tue, 21 Aug 2018 16:16:04 +0100 Subject: COMPMID-1246: Check OpenCL is available before re-creating the CL Context and Queue Change-Id: I0b0be0a86d43d87ea8225f6d5e5b02b0f80e6e3a Reviewed-on: https://eu-gerrit-1.euhpc.arm.com/145034 Reviewed-by: Michele DiGiorgio Reviewed-by: Georgios Pinitas Tested-by: Jenkins --- tests/framework/Framework.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'tests/framework') diff --git a/tests/framework/Framework.cpp b/tests/framework/Framework.cpp index 182e0babcd..eea7745230 100644 --- a/tests/framework/Framework.cpp +++ b/tests/framework/Framework.cpp @@ -532,7 +532,7 @@ bool Framework::run() { #ifdef ARM_COMPUTE_CL // Every 5000 tests, reset the OpenCL context to release the allocated memory - if((id_run_test % 5000) == 0) + if(opencl_is_available() && (id_run_test % 5000) == 0) { auto ctx_properties = CLScheduler::get().context().getInfo(nullptr); auto queue_properties = CLScheduler::get().queue().getInfo(nullptr); -- cgit v1.2.1