diff --git a/cuda/psb_c_cuda_vect_mod.F90 b/cuda/psb_c_cuda_vect_mod.F90 index 9b3b6fb1..7eee128f 100644 --- a/cuda/psb_c_cuda_vect_mod.F90 +++ b/cuda/psb_c_cuda_vect_mod.F90 @@ -668,7 +668,9 @@ contains use psi_serial_mod implicit none class(psb_c_vect_cuda), intent(inout) :: x - + ! Since we are overwriting, make sure to do it + ! on the GPU side + call x%set_dev() call x%set_scal(czero) end subroutine c_cuda_zero diff --git a/cuda/psb_d_cuda_vect_mod.F90 b/cuda/psb_d_cuda_vect_mod.F90 index c98d66f6..1e6e9f2a 100644 --- a/cuda/psb_d_cuda_vect_mod.F90 +++ b/cuda/psb_d_cuda_vect_mod.F90 @@ -668,7 +668,9 @@ contains use psi_serial_mod implicit none class(psb_d_vect_cuda), intent(inout) :: x - + ! Since we are overwriting, make sure to do it + ! on the GPU side + call x%set_dev() call x%set_scal(dzero) end subroutine d_cuda_zero diff --git a/cuda/psb_i_cuda_vect_mod.F90 b/cuda/psb_i_cuda_vect_mod.F90 index a018713e..903c4a08 100644 --- a/cuda/psb_i_cuda_vect_mod.F90 +++ b/cuda/psb_i_cuda_vect_mod.F90 @@ -650,7 +650,9 @@ contains use psi_serial_mod implicit none class(psb_i_vect_cuda), intent(inout) :: x - + ! Since we are overwriting, make sure to do it + ! on the GPU side + call x%set_dev() call x%set_scal(izero) end subroutine i_cuda_zero diff --git a/cuda/psb_s_cuda_vect_mod.F90 b/cuda/psb_s_cuda_vect_mod.F90 index 55ed4a7d..3497c33e 100644 --- a/cuda/psb_s_cuda_vect_mod.F90 +++ b/cuda/psb_s_cuda_vect_mod.F90 @@ -668,7 +668,9 @@ contains use psi_serial_mod implicit none class(psb_s_vect_cuda), intent(inout) :: x - + ! Since we are overwriting, make sure to do it + ! on the GPU side + call x%set_dev() call x%set_scal(szero) end subroutine s_cuda_zero diff --git a/cuda/psb_z_cuda_vect_mod.F90 b/cuda/psb_z_cuda_vect_mod.F90 index 2114723b..8483544c 100644 --- a/cuda/psb_z_cuda_vect_mod.F90 +++ b/cuda/psb_z_cuda_vect_mod.F90 @@ -668,7 +668,9 @@ contains use psi_serial_mod implicit none class(psb_z_vect_cuda), intent(inout) :: x - + ! Since we are overwriting, make sure to do it + ! on the GPU side + call x%set_dev() call x%set_scal(zzero) end subroutine z_cuda_zero