mirror of
https://github.com/KhronosGroup/OpenCL-CTS.git
synced 2026-03-19 06:09:01 +00:00
printf: Fix printf 'mixed_format_random' (#2236)
%a or %A with printf on MSVC platforms have a default precision of 13, which is in contrast to OpenCL C specification for printf which only allows for exact digits required if precision is not specified.
This commit is contained in:
committed by
GitHub
parent
485964d87c
commit
8c298b1c3b
@@ -247,7 +247,7 @@ cl_program makeMixedFormatPrintfProgram(cl_kernel* kernel_ptr,
|
|||||||
};
|
};
|
||||||
|
|
||||||
std::array<std::vector<std::string>, 2> formats = {
|
std::array<std::vector<std::string>, 2> formats = {
|
||||||
{ { "%f", "%e", "%g", "%a", "%F", "%E", "%G", "%A" },
|
{ { "%f", "%e", "%g", "%13a", "%F", "%E", "%G", "%13A" },
|
||||||
{ "%d", "%i", "%u", "%x", "%o", "%X" } }
|
{ "%d", "%i", "%u", "%x", "%o", "%X" } }
|
||||||
};
|
};
|
||||||
std::vector<char> data_before(2 + genrand_int32(gMTdata) % 8);
|
std::vector<char> data_before(2 + genrand_int32(gMTdata) % 8);
|
||||||
|
|||||||
Reference in New Issue
Block a user