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

Rename DLContext to DLDevice #62

Merged
merged 5 commits into from Feb 20, 2021
Merged

Rename DLContext to DLDevice #62

merged 5 commits into from Feb 20, 2021

Conversation

icemelon
Copy link
Contributor

This is the PR for the RFC #61 .

As discussed in the RFC, we will rename DLContext to DLDevice and provide DLContext as an alias via typedef.

cc: @tqchen @junrushao1994 @leofang @szha @kkraus14

include/dlpack/dlpack.h Show resolved Hide resolved
@tqchen tqchen merged commit 8323706 into dmlc:main Feb 20, 2021
@tqchen
Copy link
Member

tqchen commented Feb 20, 2021

Thanks @icemelon9 ! This PR is being merged

@icemelon icemelon deleted the rename-ctx branch February 20, 2021 00:14
@leofang
Copy link
Contributor

leofang commented Feb 20, 2021

Thanks!

/*! \brief The device context of the tensor */
DLContext ctx;
/*! \brief The device of the tensor */
DLDevice device;
Copy link
Contributor

Choose a reason for hiding this comment

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

@tqchen @icemelon9 Unfortunately this breaks existing C code. Could you please revert the field name to ctx?

Copy link
Member

Choose a reason for hiding this comment

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

@leofang this is intentional to keep the code consistent. The existing codebase can either stay at previous version, or upgrade the code to move to the new version. Exchange won't be affected by the version being used

Copy link
Contributor

Choose a reason for hiding this comment

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

Ah OK, thanks. I failed to see this implication earlier.

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.

None yet

4 participants