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

Update mdspan to account for changes to extents #751

Merged
merged 5 commits into from
Jul 26, 2022

Conversation

divyegala
Copy link
Member

@divyegala divyegala commented Jul 22, 2022

extents now allows for an IndexType to index dimensions. This PR reflects those updates and tags to kokkos/mdspan@3309ce9

The update also follows three API changes:

  1. raft::mdarray/mdspan::data() is renamed to raft::mdarray/mdspan::data_handle()
  2. raft::mdarray/mdspan::is_contiguous() is renamed to raft::mdarray/mdspan::is_exhaustive()
  3. raft::mdarray/mdspan::is_always_contiguous() is renamed to raft::mdarray/mdspan::is_always_exhaustive()

@divyegala divyegala requested review from a team as code owners July 22, 2022 19:10
@divyegala divyegala added feature request New feature or request breaking Breaking change labels Jul 22, 2022
Copy link
Member

@ajschmidt8 ajschmidt8 left a comment

Choose a reason for hiding this comment

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

Approving ops-codeowner file changes

{
return extents_type::rank();
}
[[nodiscard]] MDSPAN_INLINE_FUNCTION static constexpr auto rank_dynamic() noexcept -> index_type
[[nodiscard]] MDSPAN_INLINE_FUNCTION static constexpr auto rank_dynamic() noexcept -> std::size_t
Copy link
Member

Choose a reason for hiding this comment

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

Is the mdarray itself not able to return index_type?

Copy link
Member Author

Choose a reason for hiding this comment

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

Done

device_matrix_view<Type, layout> const x,
device_matrix_view<Type, layout> const y,
device_matrix_view<Type, layout> dist,
device_matrix_view<Type, Index_, layout> const x,
Copy link
Member

Choose a reason for hiding this comment

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

If we add the Index_ as a third type, we can default it to std::size_t and then we won't break any APIs downstream.

Copy link
Member Author

Choose a reason for hiding this comment

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

Will do, although it will be non-breaking if default is int as that is what it was before

@cjnolet
Copy link
Member

cjnolet commented Jul 26, 2022

@gpucibot merge

@rapids-bot rapids-bot bot merged commit 3b4b174 into rapidsai:branch-22.08 Jul 26, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
breaking Breaking change CMake cpp feature request New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants