Skip to content

Commit

Permalink
NFC: spirv_new - test_decorate refactoring.
Browse files Browse the repository at this point in the history
  • Loading branch information
cycheng committed Jun 20, 2024
1 parent c030617 commit ce1b216
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions test_conformance/spirv_new/test_decorate.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -324,10 +324,11 @@ int verify_saturated_results(cl_device_id deviceID, cl_context context,
err = clEnqueueReadBuffer(queue, res, CL_TRUE, 0, out_bytes, &h_res[0], 0, NULL, NULL);
SPIRV_CHECK_ERROR(err, "Failed to read to output");

cl_half_rounding_mode half_rounding = get_half_rounding_mode(deviceID);

for (int i = 0; i < num; i++)
{
To val = compute_saturated_output<Ti, Tl, To>(h_lhs[i], h_rhs[i],
get_half_rounding_mode(deviceID));
To val = compute_saturated_output<Ti, Tl, To>(h_lhs[i], h_rhs[i], half_rounding);

if (val != h_res[i])
{
Expand Down

0 comments on commit ce1b216

Please sign in to comment.