diff --git a/test_conformance/math_brute_force/macro_unary_half.cpp b/test_conformance/math_brute_force/macro_unary_half.cpp index 3d59380206..755b772cd6 100644 --- a/test_conformance/math_brute_force/macro_unary_half.cpp +++ b/test_conformance/math_brute_force/macro_unary_half.cpp @@ -103,7 +103,9 @@ int TestMacro_Int_Half(const Func *f, MTdata d, bool relaxedMode) } else { - test_info.jobCount = (cl_uint)((1ULL << 32) / test_info.step); + test_info.jobCount = + std::max((cl_uint)1, + (cl_uint)((1ULL << sizeof(cl_half) * 8) / test_info.step)); } test_info.f = f; diff --git a/test_conformance/math_brute_force/unary_half.cpp b/test_conformance/math_brute_force/unary_half.cpp index f5de28d0d5..5b0eab4c63 100644 --- a/test_conformance/math_brute_force/unary_half.cpp +++ b/test_conformance/math_brute_force/unary_half.cpp @@ -113,7 +113,9 @@ int TestFunc_Half_Half(const Func *f, MTdata d, bool relaxedMode) } else { - test_info.jobCount = (cl_uint)((1ULL << 32) / test_info.step); + test_info.jobCount = + std::max((cl_uint)1, + (cl_uint)((1ULL << sizeof(cl_half) * 8) / test_info.step)); } test_info.f = f;