Skip to content

Commit

Permalink
[ROCm] fix bfloat16 support, test=develop (PaddlePaddle#40401)
Browse files Browse the repository at this point in the history
  • Loading branch information
qili93 authored and liqitong-a committed Mar 17, 2022
1 parent 25593ec commit 456e0bb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion paddle/fluid/imperative/gradient_accumulator.cc
Original file line number Diff line number Diff line change
Expand Up @@ -423,7 +423,7 @@ void TensorAdd(const VarType& src, VarType* dst) {
}
if (data_type == framework::proto::VarType::BF16) {
if (platform::is_gpu_place(place)) {
#if defined(PADDLE_WITH_CUDA)
#if defined(PADDLE_WITH_CUDA) || defined(PADDLE_WITH_HIP)
return TensorAddImpl<platform::CUDADeviceContext, platform::bfloat16>(
src_tensor, dst_tensor, place);
#else
Expand Down

0 comments on commit 456e0bb

Please sign in to comment.