Open
Conversation
a42cce8 to
bb0ff46
Compare
shajder
requested changes
Sep 29, 2023
Comment on lines
+4520
to
+4522
| static cl_int clCreateKernelsInProgram_testcreateKernels( | ||
| cl_program program, cl_uint num_kernels, cl_kernel *kernels, | ||
| cl_uint *num_kernels_ret, int num_calls) { |
Collaborator
There was a problem hiding this comment.
We should test num_kernels value and kernels pointer against nullptr. If that is the case we should return CL_INVALID_VALUE. If this procedure returns CL_SUCCESS then num_kernels_ret should be set to num_kernels
tests/test_openclhpp.cpp
Outdated
| return CL_SUCCESS; | ||
| case 3: | ||
| TEST_ASSERT_EQUAL(make_program(1), program); | ||
| return CL_DEVICE_NOT_FOUND; |
Collaborator
There was a problem hiding this comment.
In case 3 and 4 we should set num_kernels_ret to zero for consistency.
Comment on lines
+4554
to
+4555
| ret = programPool[0].createKernels(&kernels); | ||
| TEST_ASSERT_EQUAL(CL_SUCCESS, ret); |
Collaborator
There was a problem hiding this comment.
We could also test size of the vector.
shajder
requested changes
Sep 29, 2023
| @@ -4516,5 +4516,46 @@ void testgetObjectInfo() { | |||
| TEST_ASSERT_EQUAL(buffer.getObjectInfo(&type, &bufobj), CL_SUCCESS); | |||
| TEST_ASSERT_EQUAL(type, CL_GL_OBJECT_BUFFER); | |||
| TEST_ASSERT_EQUAL(bufobj, 0); | |||
Collaborator
There was a problem hiding this comment.
Here is a compilation error. Missing } at the end of this procedure.
Collaborator
There was a problem hiding this comment.
@shajder Added some corrections to all comments. Please take a look and review.
8a21a07 to
413d854
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.