Correction to the psb_geinv implementation for out flag handling

merge-paraggr-newops
Cirdans-Home 5 years ago
parent 92fddf917b
commit 15f89400c3

@ -112,6 +112,7 @@ subroutine psb_cinv_vect_check(x,y,desc_a,info,flag)
type(psb_desc_type), intent (in) :: desc_a
integer(psb_ipk_), intent(out) :: info
logical, intent(in) :: flag
logical :: check
! locals
integer(psb_ipk_) :: ictxt, np, me,&
@ -169,6 +170,20 @@ subroutine psb_cinv_vect_check(x,y,desc_a,info,flag)
call y%inv(x,info,flag)
end if
if (info == 1_psb_ipk_) then
check = .FALSE.
else
check = .TRUE.
end if
call psb_lallreduceand(ictxt,check)
if (check) then
info = 1_psb_ipk_
else
info = 0_psb_ipk_
end if
call psb_erractionrestore(err_act)
return

@ -112,6 +112,7 @@ subroutine psb_dinv_vect_check(x,y,desc_a,info,flag)
type(psb_desc_type), intent (in) :: desc_a
integer(psb_ipk_), intent(out) :: info
logical, intent(in) :: flag
logical :: check
! locals
integer(psb_ipk_) :: ictxt, np, me,&
@ -169,6 +170,20 @@ subroutine psb_dinv_vect_check(x,y,desc_a,info,flag)
call y%inv(x,info,flag)
end if
if (info == 1_psb_ipk_) then
check = .FALSE.
else
check = .TRUE.
end if
call psb_lallreduceand(ictxt,check)
if (check) then
info = 1_psb_ipk_
else
info = 0_psb_ipk_
end if
call psb_erractionrestore(err_act)
return

@ -112,6 +112,7 @@ subroutine psb_sinv_vect_check(x,y,desc_a,info,flag)
type(psb_desc_type), intent (in) :: desc_a
integer(psb_ipk_), intent(out) :: info
logical, intent(in) :: flag
logical :: check
! locals
integer(psb_ipk_) :: ictxt, np, me,&
@ -169,6 +170,20 @@ subroutine psb_sinv_vect_check(x,y,desc_a,info,flag)
call y%inv(x,info,flag)
end if
if (info == 1_psb_ipk_) then
check = .FALSE.
else
check = .TRUE.
end if
call psb_lallreduceand(ictxt,check)
if (check) then
info = 1_psb_ipk_
else
info = 0_psb_ipk_
end if
call psb_erractionrestore(err_act)
return

@ -112,6 +112,7 @@ subroutine psb_zinv_vect_check(x,y,desc_a,info,flag)
type(psb_desc_type), intent (in) :: desc_a
integer(psb_ipk_), intent(out) :: info
logical, intent(in) :: flag
logical :: check
! locals
integer(psb_ipk_) :: ictxt, np, me,&
@ -169,6 +170,20 @@ subroutine psb_zinv_vect_check(x,y,desc_a,info,flag)
call y%inv(x,info,flag)
end if
if (info == 1_psb_ipk_) then
check = .FALSE.
else
check = .TRUE.
end if
call psb_lallreduceand(ictxt,check)
if (check) then
info = 1_psb_ipk_
else
info = 0_psb_ipk_
end if
call psb_erractionrestore(err_act)
return

Loading…
Cancel
Save