Skip to content

Commit

Permalink
[OpenCL] Registers Conv2DBackpropFilter (#28)
Browse files Browse the repository at this point in the history
* [OpenCL] Registers Conv2DBackpropFilter

* Aligned '\'
  • Loading branch information
jeffmak authored and Luke Iwanski committed Jun 5, 2017
1 parent 496eed8 commit 3b38766
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions tensorflow/core/kernels/conv_grad_filter_ops.cc
Expand Up @@ -90,6 +90,9 @@ namespace tensorflow {

typedef Eigen::ThreadPoolDevice CPUDevice;
typedef Eigen::GpuDevice GPUDevice;
#ifdef TENSORFLOW_USE_SYCL
typedef Eigen::SyclDevice SYCLDevice;
#endif // TENSORFLOW_USE_SYCL

#ifdef TENSORFLOW_USE_LIBXSMM
template <typename Device, class T>
Expand Down Expand Up @@ -911,4 +914,15 @@ REGISTER_KERNEL_BUILDER(Name("Conv2DBackpropFilter")
Conv2DSlowBackpropFilterOp<GPUDevice, Eigen::half>);
#endif // GOOGLE_CUDA

#ifdef TENSORFLOW_USE_SYCL
#define REGISTER_SYCL_KERNELS(T) \
REGISTER_KERNEL_BUILDER(Name("Conv2DBackpropFilter") \
.Device(DEVICE_SYCL) \
.Label("eigen_tensor") \
.TypeConstraint<T>("T"), \
Conv2DFastBackpropFilterOp<SYCLDevice, T>);
REGISTER_SYCL_KERNELS(float);
#undef REGISTER_SYCL_KERNELS
#endif // TENSORFLOW_USE_SYCL

} // namespace tensorflow

0 comments on commit 3b38766

Please sign in to comment.