Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix naming inconsistency khr #244

Open
wants to merge 9 commits into
base: main
Choose a base branch
from

Conversation

Bogumil-Sapinski-Mobica
Copy link
Contributor

No description provided.

Copy link
Contributor

@bashbaug bashbaug left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, this looks like the right direction, but the inconsistency still exists because now the CommandBuffer and MutableCommandBuffer classes are in the khr namespace, but the Semaphore class is not. Are you planning to move the Semaphore class into the khr namespace also?

As an aside, it looks like parts of this file were reformatted but had no other changes. I would generally advise against this, but if would like to reformat parts of the file could you please do it as the first or last commit? This will make it easier to see and review the non-formatting changes - thanks!

@Bogumil-Sapinski-Mobica
Copy link
Contributor Author

Hi @bashbaug
sorry for mixing formatting changes with task related changes.
Would you like me to create new PR with these changes or should I continue with Semaphore?

@bashbaug
Copy link
Contributor

Related to #233

Copy link
Contributor

@bashbaug bashbaug left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, this mostly looks good to me, thanks for making these changes.

I have one specific comment for the test changes, see below.

Additionally, I'd like to reiterate that formatting related changes make it much harder to review this PR than it should be. I'd strongly recommend reverting the formatting changes to minimize diffs.

Finally it appears that this PR needs a rebase since there are merge conflicts.

Comment on lines 515 to 517
namespace cl{
MAKE_MOVE_TESTS(Context, make_context, clReleaseContext, contextPool)

}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a little ugly. How about this as an alternative:

  1. Separate out the "type" and the "typestr", whereas we just have a single "type" currently.
  2. Use Context as the "typestr" in this case, and e.g. CommandBuffer as the "typestr" in the command buffer cases.
  3. Use cl::Context as the "type" in this case, and e.g. cl::khr::CommandBuffer as the "type" in the command buffer cases.

I think this will require fewer diffs, and it won't require putting the tests themselves inside of the cl or cl::khr namespaces, which they really shouldn't be doing.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@bashbaug In last commit (73c5491 73c5491) I have added corrections and removed not needed style corrections.

@CLAassistant
Copy link

CLAassistant commented Sep 25, 2023

CLA assistant check
All committers have signed the CLA.

@kamil-goras-mobica kamil-goras-mobica force-pushed the fix_naming_inconsistency_khr branch 3 times, most recently from 139167b to f98dfed Compare September 25, 2023 12:46
@kamil-goras-mobica kamil-goras-mobica force-pushed the fix_naming_inconsistency_khr branch from f98dfed to 73c5491 Compare September 25, 2023 12:49
Copy link
Contributor

@bashbaug bashbaug left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Apologies for the long review delay. The updated change LGTM. There needs to be a rebase (in the test code?) now, but hopefully that is straightforward.

Noting for completeness: these changes do break backward compatibility so they will require code changes for applications using the C++ bindings with semaphores and command buffers.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants