Description
Hi, I am trying to port my code to version 0.16, and trying to understand cudaStreamSynchronize
. When is it needed? The different layers seem to inconsistently use it.
For example, it is included here:
https://github.com/NVIDIA/caffe/blob/caffe-0.16/src/caffe/layers/relu_layer.cu#L54
https://github.com/NVIDIA/caffe/blob/caffe-0.16/src/caffe/layers/bias_layer.cu#L27
https://github.com/NVIDIA/caffe/blob/caffe-0.16/src/caffe/layers/bnll_layer.cu#L26
...
But not here:
https://github.com/NVIDIA/caffe/blob/caffe-0.16/src/caffe/layers/scale_layer.cu#L47
https://github.com/NVIDIA/caffe/blob/caffe-0.16/src/caffe/layers/slice_layer.cu#L40
https://github.com/NVIDIA/caffe/blob/caffe-0.16/src/caffe/layers/threshold_layer.cu#L22
https://github.com/NVIDIA/caffe/blob/caffe-0.16/src/caffe/layers/tile_layer.cu#L28
https://github.com/NVIDIA/caffe/blob/caffe-0.16/src/caffe/layers/batch_reindex_layer.cu#L30
https://github.com/NVIDIA/caffe/blob/caffe-0.16/src/caffe/layers/tanh_layer.cu#L24
https://github.com/NVIDIA/caffe/blob/caffe-0.16/src/caffe/layers/crop_layer.cu#L70
...
(Some are potentially also missing the kernel check)
These are incomplete lists, more files may be missing it.