-
Notifications
You must be signed in to change notification settings - Fork 172
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
Provide span abstractions for host and device memory #752
Comments
Another strategy is to follow the |
@hcedwar yeah, I think we'll end up doing something like that for libcu++; however, the Thrust types are more involved and should follow the pattern of allowing access to device-only memory from the host by copying it when used with non-managed memory. These would serve a slightly different usage pattern than the libcu++ ones. |
I think Carter is correct that we will have tagged span types, just as
vector_base and pointer are tagged.
…On Mon, Nov 16, 2020 at 8:23 PM Michał Dominiak ***@***.***> wrote:
@hcedwar <https://github.com/hcedwar> yeah, I think we'll end up doing
something like that for libcu++; however, the Thrust types are more
involved and should follow the pattern of allowing access to device-only
memory from the host by copying it when used with non-managed memory. These
would serve a slightly different usage pattern than the libcu++ ones.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#752>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AADBG4WTIEEJCZJZPIZT2CDSQH3E5ANCNFSM4TNB46EQ>
.
--
Bryce Adelstein Lelbach aka wash (he/him/his)
US Programming Language Standards (PL22) Chair
ISO C++ Library Evolution Chair
CppCon and C++Now Program Chair
C++ Core Compute Libraries (Thrust, CUB, libcu++) Lead @ NVIDIA
--
|
@hschwane submitted NVIDIA/thrust#1407, which implements a |
Hello! Are there any news on implementing this? |
libcu++ now provides However, there is no device or host specific span type yet. That is something we're still talking about though. |
I would like Thrust to provide the equivalent of a
std::span
, i.e., a non-owning view of a contiguous sequence of objects.Like
host_vector
anddevice_vector
, I believe there should be separatehost_span
anddevice_span
(anduniversal
?) classes to indicate if the data is safe to touch from host or device.A key requirement is that
device_span
must work to pass by value and is usable directly into CUDA kernels, e.g.,The text was updated successfully, but these errors were encountered: