diff options
Diffstat (limited to 'parallel-libs/streamexecutor/examples/CUDASaxpy.cpp')
| -rw-r--r-- | parallel-libs/streamexecutor/examples/CUDASaxpy.cpp | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/parallel-libs/streamexecutor/examples/CUDASaxpy.cpp b/parallel-libs/streamexecutor/examples/CUDASaxpy.cpp index 0fce5ed046b..6b2c59e5cd6 100644 --- a/parallel-libs/streamexecutor/examples/CUDASaxpy.cpp +++ b/parallel-libs/streamexecutor/examples/CUDASaxpy.cpp @@ -108,25 +108,25 @@ int main() { if (Platform->getDeviceCount() == 0) { return EXIT_FAILURE; } - se::Device *Device = getOrDie(Platform->getDevice(0)); + se::Device Device = getOrDie(Platform->getDevice(0)); // Load the kernel onto the device. cg::SaxpyKernel Kernel = - getOrDie(Device->createKernel<cg::SaxpyKernel>(cg::SaxpyLoaderSpec)); + getOrDie(Device.createKernel<cg::SaxpyKernel>(cg::SaxpyLoaderSpec)); se::RegisteredHostMemory<float> RegisteredX = - getOrDie(Device->registerHostMemory<float>(HostX)); + getOrDie(Device.registerHostMemory<float>(HostX)); se::RegisteredHostMemory<float> RegisteredY = - getOrDie(Device->registerHostMemory<float>(HostY)); + getOrDie(Device.registerHostMemory<float>(HostY)); // Allocate memory on the device. se::GlobalDeviceMemory<float> X = - getOrDie(Device->allocateDeviceMemory<float>(ArraySize)); + getOrDie(Device.allocateDeviceMemory<float>(ArraySize)); se::GlobalDeviceMemory<float> Y = - getOrDie(Device->allocateDeviceMemory<float>(ArraySize)); + getOrDie(Device.allocateDeviceMemory<float>(ArraySize)); // Run operations on a stream. - se::Stream Stream = getOrDie(Device->createStream()); + se::Stream Stream = getOrDie(Device.createStream()); Stream.thenCopyH2D(RegisteredX, X) .thenCopyH2D(RegisteredY, Y) .thenLaunch(ArraySize, 1, Kernel, A, X, Y) |

