aboutsummaryrefslogtreecommitdiffhomepage
path: root/unsupported/Eigen/CXX11/src/Tensor/TensorDeviceGpu.h
diff options
context:
space:
mode:
authorGravatar Mehdi Goli <mehdi.goli@codeplay.com>2018-08-01 16:56:26 +0100
committerGravatar Mehdi Goli <mehdi.goli@codeplay.com>2018-08-01 16:56:26 +0100
commitc6a5c70712851cd696d7410579506fc299c04a05 (patch)
treea80a1ab98f22c51e263137e23b7e84db1dc47232 /unsupported/Eigen/CXX11/src/Tensor/TensorDeviceGpu.h
parentd7a84148483b1a11b993c037a2cea5b43f2c052f (diff)
Correcting the position of allocate_temp/deallocate_temp in TensorDeviceGpu.h
Diffstat (limited to 'unsupported/Eigen/CXX11/src/Tensor/TensorDeviceGpu.h')
-rw-r--r--unsupported/Eigen/CXX11/src/Tensor/TensorDeviceGpu.h16
1 files changed, 9 insertions, 7 deletions
diff --git a/unsupported/Eigen/CXX11/src/Tensor/TensorDeviceGpu.h b/unsupported/Eigen/CXX11/src/Tensor/TensorDeviceGpu.h
index 48bbd5e45..b490433db 100644
--- a/unsupported/Eigen/CXX11/src/Tensor/TensorDeviceGpu.h
+++ b/unsupported/Eigen/CXX11/src/Tensor/TensorDeviceGpu.h
@@ -159,13 +159,6 @@ class GpuStreamDevice : public StreamInterface {
err = gpuFree(buffer);
gpu_assert(err == gpuSuccess);
}
- EIGEN_STRONG_INLINE void* allocate_temp(size_t num_bytes) const {
- return stream_->allocate(num_bytes);
- }
-
- EIGEN_STRONG_INLINE void deallocate_temp(void* buffer) const {
- stream_->deallocate(buffer);
- }
virtual void* scratchpad() const {
if (scratch_ == NULL) {
@@ -214,6 +207,15 @@ struct GpuDevice {
stream_->deallocate(buffer);
}
+ EIGEN_STRONG_INLINE void* allocate_temp(size_t num_bytes) const {
+ return stream_->allocate(num_bytes);
+ }
+
+ EIGEN_STRONG_INLINE void deallocate_temp(void* buffer) const {
+ stream_->deallocate(buffer);
+ }
+
+
EIGEN_STRONG_INLINE void* scratchpad() const {
return stream_->scratchpad();
}