Change handling of no-context in DESC for remap-coarse

new-context
Salvatore Filippone 4 years ago
parent 2de1202d62
commit 90493218a2

@ -614,8 +614,8 @@ contains
val = desc%indxmap%get_ctxt() val = desc%indxmap%get_ctxt()
else else
val = -1 val = -1
call psb_errpush(psb_err_invalid_cd_state_,'psb_cd_get_context') !!$ call psb_errpush(psb_err_invalid_cd_state_,'psb_cd_get_context')
call psb_error() !!$ call psb_error()
end if end if
end function psb_cd_get_context end function psb_cd_get_context
@ -629,8 +629,8 @@ contains
val = desc%indxmap%get_state() val = desc%indxmap%get_state()
else else
val = -1 val = -1
call psb_errpush(psb_err_invalid_cd_state_,'psb_cd_get_dectype') !!$ call psb_errpush(psb_err_invalid_cd_state_,'psb_cd_get_dectype')
call psb_error() !!$ call psb_error()
end if end if
end function psb_cd_get_dectype end function psb_cd_get_dectype
@ -645,8 +645,8 @@ contains
val = desc%indxmap%get_mpic() val = desc%indxmap%get_mpic()
else else
val = -1 val = -1
call psb_errpush(psb_err_invalid_cd_state_,'psb_cd_get_mpic') !!$ call psb_errpush(psb_err_invalid_cd_state_,'psb_cd_get_mpic')
call psb_error() !!$ call psb_error()
end if end if
end function psb_cd_get_mpic end function psb_cd_get_mpic

@ -563,7 +563,10 @@ contains
call mpi_comm_size(ictxt,np,info) call mpi_comm_size(ictxt,np,info)
if (info /= mpi_success) np = -1 if (info /= mpi_success) np = -1
call mpi_comm_rank(ictxt,iam,info) call mpi_comm_rank(ictxt,iam,info)
if (info /= mpi_success) iam = -1 if (info /= mpi_success) iam = -1
else
np = -1
iam = -1
end if end if
lctxt = ictxt lctxt = ictxt
lam = iam lam = iam

@ -80,16 +80,25 @@ subroutine psb_dasb_vect(x, desc_a, info, mold, scratch)
scratch_ = .false. scratch_ = .false.
if (present(scratch)) scratch_ = scratch if (present(scratch)) scratch_ = scratch
call psb_info(ictxt, me, np) call psb_info(ictxt, me, np)
! ....verify blacs grid correctness.. ! ....verify blacs grid correctness..
if (np == -1) then if (.false.) then
info = psb_err_context_error_ if (np == -1) then
call psb_errpush(info,name) info = psb_err_context_error_
goto 9999 call psb_errpush(info,name)
else if (.not.desc_a%is_ok()) then goto 9999
info = psb_err_invalid_cd_state_ else if (.not.desc_a%is_ok()) then
call psb_errpush(info,name) info = psb_err_invalid_cd_state_
goto 9999 call psb_errpush(info,name)
goto 9999
end if
else
if (np == -1) then
ncol = 0
call x%bld(ncol,mold=mold)
call psb_erractionrestore(err_act)
return
end if
end if end if
nrow = desc_a%get_local_rows() nrow = desc_a%get_local_rows()

Loading…
Cancel
Save