Fixed TRANSP intent.
psblas3-type-indexed
Salvatore Filippone 13 years ago
parent d9b7abda2a
commit 61adee3c4c

@ -510,16 +510,16 @@ module psb_c_base_mat_mod
interface
subroutine psb_c_base_transp_2mat(a,b)
import :: psb_c_base_sparse_mat, psb_base_sparse_mat, psb_spk_
class(psb_c_base_sparse_mat), intent(out) :: a
class(psb_base_sparse_mat), intent(in) :: b
class(psb_c_base_sparse_mat), intent(in) :: a
class(psb_base_sparse_mat), intent(out) :: b
end subroutine psb_c_base_transp_2mat
end interface
interface
subroutine psb_c_base_transc_2mat(a,b)
import :: psb_c_base_sparse_mat, psb_base_sparse_mat, psb_spk_
class(psb_c_base_sparse_mat), intent(out) :: a
class(psb_base_sparse_mat), intent(in) :: b
class(psb_c_base_sparse_mat), intent(in) :: a
class(psb_base_sparse_mat), intent(out) :: b
end subroutine psb_c_base_transc_2mat
end interface

@ -547,8 +547,8 @@ module psb_c_mat_mod
interface
subroutine psb_c_transp_2mat(a,b)
import :: psb_cspmat_type
class(psb_cspmat_type), intent(out) :: a
class(psb_cspmat_type), intent(in) :: b
class(psb_cspmat_type), intent(in) :: a
class(psb_cspmat_type), intent(out) :: b
end subroutine psb_c_transp_2mat
end interface
@ -562,8 +562,8 @@ module psb_c_mat_mod
interface
subroutine psb_c_transc_2mat(a,b)
import :: psb_cspmat_type
class(psb_cspmat_type), intent(out) :: a
class(psb_cspmat_type), intent(in) :: b
class(psb_cspmat_type), intent(in) :: a
class(psb_cspmat_type), intent(out) :: b
end subroutine psb_c_transc_2mat
end interface

@ -511,16 +511,16 @@ module psb_d_base_mat_mod
interface
subroutine psb_d_base_transp_2mat(a,b)
import :: psb_d_base_sparse_mat, psb_base_sparse_mat, psb_dpk_
class(psb_d_base_sparse_mat), intent(out) :: a
class(psb_base_sparse_mat), intent(in) :: b
class(psb_d_base_sparse_mat), intent(in) :: a
class(psb_base_sparse_mat), intent(out) :: b
end subroutine psb_d_base_transp_2mat
end interface
interface
subroutine psb_d_base_transc_2mat(a,b)
import :: psb_d_base_sparse_mat, psb_base_sparse_mat, psb_dpk_
class(psb_d_base_sparse_mat), intent(out) :: a
class(psb_base_sparse_mat), intent(in) :: b
class(psb_d_base_sparse_mat), intent(in) :: a
class(psb_base_sparse_mat), intent(out) :: b
end subroutine psb_d_base_transc_2mat
end interface

@ -108,6 +108,7 @@ module psb_d_mat_mod
procedure, pass(a) :: d_cscnv_ip => psb_d_cscnv_ip
procedure, pass(a) :: d_cscnv_base => psb_d_cscnv_base
generic, public :: cscnv => d_cscnv, d_cscnv_ip, d_cscnv_base
procedure, pass(a) :: clone => psb_dspmat_type_clone
procedure, pass(a) :: reinit => psb_d_reinit
procedure, pass(a) :: print_i => psb_d_sparse_print
procedure, pass(a) :: print_n => psb_d_n_sparse_print
@ -549,8 +550,8 @@ module psb_d_mat_mod
interface
subroutine psb_d_transp_2mat(a,b)
import :: psb_dspmat_type
class(psb_dspmat_type), intent(out) :: a
class(psb_dspmat_type), intent(in) :: b
class(psb_dspmat_type), intent(in) :: a
class(psb_dspmat_type), intent(out) :: b
end subroutine psb_d_transp_2mat
end interface
@ -564,8 +565,8 @@ module psb_d_mat_mod
interface
subroutine psb_d_transc_2mat(a,b)
import :: psb_dspmat_type
class(psb_dspmat_type), intent(out) :: a
class(psb_dspmat_type), intent(in) :: b
class(psb_dspmat_type), intent(in) :: a
class(psb_dspmat_type), intent(out) :: b
end subroutine psb_d_transc_2mat
end interface

@ -511,16 +511,16 @@ module psb_s_base_mat_mod
interface
subroutine psb_s_base_transp_2mat(a,b)
import :: psb_s_base_sparse_mat, psb_base_sparse_mat, psb_spk_
class(psb_s_base_sparse_mat), intent(out) :: a
class(psb_base_sparse_mat), intent(in) :: b
class(psb_s_base_sparse_mat), intent(in) :: a
class(psb_base_sparse_mat), intent(out) :: b
end subroutine psb_s_base_transp_2mat
end interface
interface
subroutine psb_s_base_transc_2mat(a,b)
import :: psb_s_base_sparse_mat, psb_base_sparse_mat, psb_spk_
class(psb_s_base_sparse_mat), intent(out) :: a
class(psb_base_sparse_mat), intent(in) :: b
class(psb_s_base_sparse_mat), intent(in) :: a
class(psb_base_sparse_mat), intent(out) :: b
end subroutine psb_s_base_transc_2mat
end interface

@ -550,8 +550,8 @@ module psb_s_mat_mod
interface
subroutine psb_s_transp_2mat(a,b)
import :: psb_sspmat_type
class(psb_sspmat_type), intent(out) :: a
class(psb_sspmat_type), intent(in) :: b
class(psb_sspmat_type), intent(in) :: a
class(psb_sspmat_type), intent(out) :: b
end subroutine psb_s_transp_2mat
end interface
@ -565,8 +565,8 @@ module psb_s_mat_mod
interface
subroutine psb_s_transc_2mat(a,b)
import :: psb_sspmat_type
class(psb_sspmat_type), intent(out) :: a
class(psb_sspmat_type), intent(in) :: b
class(psb_sspmat_type), intent(in) :: a
class(psb_sspmat_type), intent(out) :: b
end subroutine psb_s_transc_2mat
end interface

@ -512,16 +512,16 @@ module psb_z_base_mat_mod
interface
subroutine psb_z_base_transp_2mat(a,b)
import :: psb_z_base_sparse_mat, psb_base_sparse_mat, psb_dpk_
class(psb_z_base_sparse_mat), intent(out) :: a
class(psb_base_sparse_mat), intent(in) :: b
class(psb_z_base_sparse_mat), intent(in) :: a
class(psb_base_sparse_mat), intent(out) :: b
end subroutine psb_z_base_transp_2mat
end interface
interface
subroutine psb_z_base_transc_2mat(a,b)
import :: psb_z_base_sparse_mat, psb_base_sparse_mat, psb_dpk_
class(psb_z_base_sparse_mat), intent(out) :: a
class(psb_base_sparse_mat), intent(in) :: b
class(psb_z_base_sparse_mat), intent(in) :: a
class(psb_base_sparse_mat), intent(out) :: b
end subroutine psb_z_base_transc_2mat
end interface

@ -547,8 +547,8 @@ module psb_z_mat_mod
interface
subroutine psb_z_transp_2mat(a,b)
import :: psb_zspmat_type
class(psb_zspmat_type), intent(out) :: a
class(psb_zspmat_type), intent(in) :: b
class(psb_zspmat_type), intent(in) :: a
class(psb_zspmat_type), intent(out) :: b
end subroutine psb_z_transp_2mat
end interface
@ -562,8 +562,8 @@ module psb_z_mat_mod
interface
subroutine psb_z_transc_2mat(a,b)
import :: psb_zspmat_type
class(psb_zspmat_type), intent(out) :: a
class(psb_zspmat_type), intent(in) :: b
class(psb_zspmat_type), intent(in) :: a
class(psb_zspmat_type), intent(out) :: b
end subroutine psb_z_transc_2mat
end interface

@ -473,8 +473,8 @@ subroutine psb_c_base_transp_2mat(a,b)
use psb_error_mod
implicit none
class(psb_c_base_sparse_mat), intent(out) :: a
class(psb_base_sparse_mat), intent(in) :: b
class(psb_c_base_sparse_mat), intent(in) :: a
class(psb_base_sparse_mat), intent(out) :: b
type(psb_c_coo_sparse_mat) :: tmp
integer err_act, info
@ -485,9 +485,9 @@ subroutine psb_c_base_transp_2mat(a,b)
info = psb_success_
select type(b)
class is (psb_c_base_sparse_mat)
call b%cp_to_coo(tmp,info)
call a%cp_to_coo(tmp,info)
if (info == psb_success_) call tmp%transp()
if (info == psb_success_) call a%mv_from_coo(tmp,info)
if (info == psb_success_) call b%mv_from_coo(tmp,info)
class default
info = psb_err_invalid_dynamic_type_
end select
@ -511,8 +511,8 @@ subroutine psb_c_base_transc_2mat(a,b)
use psb_c_base_mat_mod, psb_protect_name => psb_c_base_transc_2mat
implicit none
class(psb_c_base_sparse_mat), intent(out) :: a
class(psb_base_sparse_mat), intent(in) :: b
class(psb_c_base_sparse_mat), intent(in) :: a
class(psb_base_sparse_mat), intent(out) :: b
type(psb_c_coo_sparse_mat) :: tmp
integer err_act, info
@ -523,9 +523,9 @@ subroutine psb_c_base_transc_2mat(a,b)
info = psb_success_
select type(b)
class is (psb_c_base_sparse_mat)
call b%cp_to_coo(tmp,info)
call a%cp_to_coo(tmp,info)
if (info == psb_success_) call tmp%transc()
if (info == psb_success_) call a%mv_from_coo(tmp,info)
if (info == psb_success_) call b%mv_from_coo(tmp,info)
class default
info = psb_err_invalid_dynamic_type_
end select

@ -1589,8 +1589,8 @@ subroutine psb_c_transp_2mat(a,b)
use psb_string_mod
use psb_c_mat_mod, psb_protect_name => psb_c_transp_2mat
implicit none
class(psb_cspmat_type), intent(out) :: a
class(psb_cspmat_type), intent(in) :: b
class(psb_cspmat_type), intent(in) :: a
class(psb_cspmat_type), intent(out) :: b
Integer :: err_act, info
character(len=20) :: name='transp'
@ -1598,22 +1598,22 @@ subroutine psb_c_transp_2mat(a,b)
call psb_erractionsave(err_act)
if (b%is_null()) then
if (a%is_null()) then
info = psb_err_invalid_mat_state_
call psb_errpush(info,name)
goto 9999
endif
#if defined(HAVE_MOLD)
allocate(a%a,mold=b%a,stat=info)
allocate(b%a,mold=a%a,stat=info)
#else
call b%a%mold(a%a,info)
call a%a%mold(b%a,info)
#endif
if (info /= psb_success_) then
info = psb_err_alloc_dealloc_
goto 9999
end if
call a%a%transp(b%a)
call a%a%transp_2mat(b%a)
call psb_erractionrestore(err_act)
return
@ -1670,8 +1670,8 @@ subroutine psb_c_transc_2mat(a,b)
use psb_string_mod
use psb_c_mat_mod, psb_protect_name => psb_c_transc_2mat
implicit none
class(psb_cspmat_type), intent(out) :: a
class(psb_cspmat_type), intent(in) :: b
class(psb_cspmat_type), intent(in) :: a
class(psb_cspmat_type), intent(out) :: b
Integer :: err_act, info
character(len=20) :: name='transc'
@ -1679,22 +1679,22 @@ subroutine psb_c_transc_2mat(a,b)
call psb_erractionsave(err_act)
if (b%is_null()) then
if (a%is_null()) then
info = psb_err_invalid_mat_state_
call psb_errpush(info,name)
goto 9999
endif
#if defined(HAVE_MOLD)
allocate(a%a,mold=b%a,stat=info)
allocate(b%a,mold=a%a,stat=info)
#else
call b%a%mold(a%a,info)
call a%a%mold(b%a,info)
#endif
if (info /= psb_success_) then
info = psb_err_alloc_dealloc_
goto 9999
end if
call a%a%transc(b%a)
call a%a%transc_2mat(b%a)
call psb_erractionrestore(err_act)
return

@ -473,8 +473,8 @@ subroutine psb_d_base_transp_2mat(a,b)
use psb_error_mod
implicit none
class(psb_d_base_sparse_mat), intent(out) :: a
class(psb_base_sparse_mat), intent(in) :: b
class(psb_d_base_sparse_mat), intent(in) :: a
class(psb_base_sparse_mat), intent(out) :: b
type(psb_d_coo_sparse_mat) :: tmp
integer err_act, info
@ -485,9 +485,9 @@ subroutine psb_d_base_transp_2mat(a,b)
info = psb_success_
select type(b)
class is (psb_d_base_sparse_mat)
call b%cp_to_coo(tmp,info)
call a%cp_to_coo(tmp,info)
if (info == psb_success_) call tmp%transp()
if (info == psb_success_) call a%mv_from_coo(tmp,info)
if (info == psb_success_) call b%mv_from_coo(tmp,info)
class default
info = psb_err_invalid_dynamic_type_
end select
@ -511,10 +511,36 @@ subroutine psb_d_base_transc_2mat(a,b)
use psb_d_base_mat_mod, psb_protect_name => psb_d_base_transc_2mat
implicit none
class(psb_d_base_sparse_mat), intent(out) :: a
class(psb_base_sparse_mat), intent(in) :: b
class(psb_d_base_sparse_mat), intent(in) :: a
class(psb_base_sparse_mat), intent(out) :: b
type(psb_d_coo_sparse_mat) :: tmp
integer err_act, info
character(len=*), parameter :: name='d_base_transc'
call psb_erractionsave(err_act)
info = psb_success_
select type(b)
class is (psb_d_base_sparse_mat)
call a%cp_to_coo(tmp,info)
if (info == psb_success_) call tmp%transc()
if (info == psb_success_) call b%mv_from_coo(tmp,info)
class default
info = psb_err_invalid_dynamic_type_
end select
if (info /= psb_success_) then
call psb_errpush(info,name,a_err=b%get_fmt(),i_err=(/1,0,0,0,0/))
goto 9999
end if
call psb_erractionrestore(err_act)
return
9999 continue
if (err_act /= psb_act_ret_) then
call psb_error()
end if
call a%transp(b)
return
end subroutine psb_d_base_transc_2mat
subroutine psb_d_base_transp_1mat(a)

@ -1588,8 +1588,8 @@ subroutine psb_d_transp_2mat(a,b)
use psb_string_mod
use psb_d_mat_mod, psb_protect_name => psb_d_transp_2mat
implicit none
class(psb_dspmat_type), intent(out) :: a
class(psb_dspmat_type), intent(in) :: b
class(psb_dspmat_type), intent(in) :: a
class(psb_dspmat_type), intent(out) :: b
Integer :: err_act, info
character(len=20) :: name='transp'
@ -1597,22 +1597,22 @@ subroutine psb_d_transp_2mat(a,b)
call psb_erractionsave(err_act)
if (b%is_null()) then
if (a%is_null()) then
info = psb_err_invalid_mat_state_
call psb_errpush(info,name)
goto 9999
endif
#if defined(HAVE_MOLD)
allocate(a%a,mold=b%a,stat=info)
allocate(b%a,mold=a%a,stat=info)
#else
call b%a%mold(a%a,info)
call a%a%mold(b%a,info)
#endif
if (info /= psb_success_) then
info = psb_err_alloc_dealloc_
goto 9999
end if
call a%a%transp(b%a)
call a%a%transp_2mat(b%a)
call psb_erractionrestore(err_act)
return
@ -1669,8 +1669,8 @@ subroutine psb_d_transc_2mat(a,b)
use psb_string_mod
use psb_d_mat_mod, psb_protect_name => psb_d_transc_2mat
implicit none
class(psb_dspmat_type), intent(out) :: a
class(psb_dspmat_type), intent(in) :: b
class(psb_dspmat_type), intent(in) :: a
class(psb_dspmat_type), intent(out) :: b
Integer :: err_act, info
character(len=20) :: name='transc'
@ -1678,22 +1678,22 @@ subroutine psb_d_transc_2mat(a,b)
call psb_erractionsave(err_act)
if (b%is_null()) then
if (a%is_null()) then
info = psb_err_invalid_mat_state_
call psb_errpush(info,name)
goto 9999
endif
#if defined(HAVE_MOLD)
allocate(a%a,mold=b%a,stat=info)
allocate(b%a,mold=a%a,stat=info)
#else
call b%a%mold(a%a,info)
call a%a%mold(b%a,info)
#endif
if (info /= psb_success_) then
info = psb_err_alloc_dealloc_
goto 9999
end if
call a%a%transc(b%a)
call a%a%transc_2mat(b%a)
call psb_erractionrestore(err_act)
return

@ -473,8 +473,8 @@ subroutine psb_s_base_transp_2mat(a,b)
use psb_error_mod
implicit none
class(psb_s_base_sparse_mat), intent(out) :: a
class(psb_base_sparse_mat), intent(in) :: b
class(psb_s_base_sparse_mat), intent(in) :: a
class(psb_base_sparse_mat), intent(out) :: b
type(psb_s_coo_sparse_mat) :: tmp
integer err_act, info
@ -485,9 +485,9 @@ subroutine psb_s_base_transp_2mat(a,b)
info = psb_success_
select type(b)
class is (psb_s_base_sparse_mat)
call b%cp_to_coo(tmp,info)
call a%cp_to_coo(tmp,info)
if (info == psb_success_) call tmp%transp()
if (info == psb_success_) call a%mv_from_coo(tmp,info)
if (info == psb_success_) call b%mv_from_coo(tmp,info)
class default
info = psb_err_invalid_dynamic_type_
end select
@ -511,10 +511,36 @@ subroutine psb_s_base_transc_2mat(a,b)
use psb_s_base_mat_mod, psb_protect_name => psb_s_base_transc_2mat
implicit none
class(psb_s_base_sparse_mat), intent(out) :: a
class(psb_base_sparse_mat), intent(in) :: b
class(psb_s_base_sparse_mat), intent(in) :: a
class(psb_base_sparse_mat), intent(out) :: b
type(psb_s_coo_sparse_mat) :: tmp
integer err_act, info
character(len=*), parameter :: name='s_base_transc'
call psb_erractionsave(err_act)
info = psb_success_
select type(b)
class is (psb_s_base_sparse_mat)
call a%cp_to_coo(tmp,info)
if (info == psb_success_) call tmp%transc()
if (info == psb_success_) call b%mv_from_coo(tmp,info)
class default
info = psb_err_invalid_dynamic_type_
end select
if (info /= psb_success_) then
call psb_errpush(info,name,a_err=b%get_fmt(),i_err=(/1,0,0,0,0/))
goto 9999
end if
call psb_erractionrestore(err_act)
return
9999 continue
if (err_act /= psb_act_ret_) then
call psb_error()
end if
call a%transp(b)
return
end subroutine psb_s_base_transc_2mat
subroutine psb_s_base_transp_1mat(a)

@ -1587,8 +1587,8 @@ subroutine psb_s_transp_2mat(a,b)
use psb_string_mod
use psb_s_mat_mod, psb_protect_name => psb_s_transp_2mat
implicit none
class(psb_sspmat_type), intent(out) :: a
class(psb_sspmat_type), intent(in) :: b
class(psb_sspmat_type), intent(in) :: a
class(psb_sspmat_type), intent(out) :: b
Integer :: err_act, info
character(len=20) :: name='transp'
@ -1596,22 +1596,22 @@ subroutine psb_s_transp_2mat(a,b)
call psb_erractionsave(err_act)
if (b%is_null()) then
if (a%is_null()) then
info = psb_err_invalid_mat_state_
call psb_errpush(info,name)
goto 9999
endif
#if defined(HAVE_MOLD)
allocate(a%a,mold=b%a,stat=info)
allocate(b%a,mold=a%a,stat=info)
#else
call b%a%mold(a%a,info)
call a%a%mold(b%a,info)
#endif
if (info /= psb_success_) then
info = psb_err_alloc_dealloc_
goto 9999
end if
call a%a%transp(b%a)
call a%a%transp_2mat(b%a)
call psb_erractionrestore(err_act)
return
@ -1668,8 +1668,8 @@ subroutine psb_s_transc_2mat(a,b)
use psb_string_mod
use psb_s_mat_mod, psb_protect_name => psb_s_transc_2mat
implicit none
class(psb_sspmat_type), intent(out) :: a
class(psb_sspmat_type), intent(in) :: b
class(psb_sspmat_type), intent(in) :: a
class(psb_sspmat_type), intent(out) :: b
Integer :: err_act, info
character(len=20) :: name='transc'
@ -1677,22 +1677,22 @@ subroutine psb_s_transc_2mat(a,b)
call psb_erractionsave(err_act)
if (b%is_null()) then
if (a%is_null()) then
info = psb_err_invalid_mat_state_
call psb_errpush(info,name)
goto 9999
endif
#if defined(HAVE_MOLD)
allocate(a%a,mold=b%a,stat=info)
allocate(b%a,mold=a%a,stat=info)
#else
call b%a%mold(a%a,info)
call a%a%mold(b%a,info)
#endif
if (info /= psb_success_) then
info = psb_err_alloc_dealloc_
goto 9999
end if
call a%a%transc(b%a)
call a%a%transc_2mat(b%a)
call psb_erractionrestore(err_act)
return

@ -474,8 +474,8 @@ subroutine psb_z_base_transp_2mat(a,b)
use psb_error_mod
implicit none
class(psb_z_base_sparse_mat), intent(out) :: a
class(psb_base_sparse_mat), intent(in) :: b
class(psb_z_base_sparse_mat), intent(in) :: a
class(psb_base_sparse_mat), intent(out) :: b
type(psb_z_coo_sparse_mat) :: tmp
integer err_act, info
@ -486,9 +486,9 @@ subroutine psb_z_base_transp_2mat(a,b)
info = psb_success_
select type(b)
class is (psb_z_base_sparse_mat)
call b%cp_to_coo(tmp,info)
call a%cp_to_coo(tmp,info)
if (info == psb_success_) call tmp%transp()
if (info == psb_success_) call a%mv_from_coo(tmp,info)
if (info == psb_success_) call b%mv_from_coo(tmp,info)
class default
info = psb_err_invalid_dynamic_type_
end select
@ -512,8 +512,8 @@ subroutine psb_z_base_transc_2mat(a,b)
use psb_z_base_mat_mod, psb_protect_name => psb_z_base_transc_2mat
implicit none
class(psb_z_base_sparse_mat), intent(out) :: a
class(psb_base_sparse_mat), intent(in) :: b
class(psb_z_base_sparse_mat), intent(in) :: a
class(psb_base_sparse_mat), intent(out) :: b
type(psb_z_coo_sparse_mat) :: tmp
integer err_act, info
character(len=*), parameter :: name='z_base_transc'
@ -523,9 +523,9 @@ subroutine psb_z_base_transc_2mat(a,b)
info = psb_success_
select type(b)
class is (psb_z_base_sparse_mat)
call b%cp_to_coo(tmp,info)
call a%cp_to_coo(tmp,info)
if (info == psb_success_) call tmp%transc()
if (info == psb_success_) call a%mv_from_coo(tmp,info)
if (info == psb_success_) call b%mv_from_coo(tmp,info)
class default
info = psb_err_invalid_dynamic_type_
end select

@ -1587,8 +1587,8 @@ subroutine psb_z_transp_2mat(a,b)
use psb_string_mod
use psb_z_mat_mod, psb_protect_name => psb_z_transp_2mat
implicit none
class(psb_zspmat_type), intent(out) :: a
class(psb_zspmat_type), intent(in) :: b
class(psb_zspmat_type), intent(in) :: a
class(psb_zspmat_type), intent(out) :: b
Integer :: err_act, info
character(len=20) :: name='transp'
@ -1596,22 +1596,22 @@ subroutine psb_z_transp_2mat(a,b)
call psb_erractionsave(err_act)
if (b%is_null()) then
if (a%is_null()) then
info = psb_err_invalid_mat_state_
call psb_errpush(info,name)
goto 9999
endif
#if defined(HAVE_MOLD)
allocate(a%a,mold=b%a,stat=info)
allocate(b%a,mold=a%a,stat=info)
#else
call b%a%mold(a%a,info)
call a%a%mold(b%a,info)
#endif
if (info /= psb_success_) then
info = psb_err_alloc_dealloc_
goto 9999
end if
call a%a%transp(b%a)
call a%a%transp_2mat(b%a)
call psb_erractionrestore(err_act)
return
@ -1668,8 +1668,8 @@ subroutine psb_z_transc_2mat(a,b)
use psb_string_mod
use psb_z_mat_mod, psb_protect_name => psb_z_transc_2mat
implicit none
class(psb_zspmat_type), intent(out) :: a
class(psb_zspmat_type), intent(in) :: b
class(psb_zspmat_type), intent(in) :: a
class(psb_zspmat_type), intent(out) :: b
Integer :: err_act, info
character(len=20) :: name='transc'
@ -1677,22 +1677,22 @@ subroutine psb_z_transc_2mat(a,b)
call psb_erractionsave(err_act)
if (b%is_null()) then
if (a%is_null()) then
info = psb_err_invalid_mat_state_
call psb_errpush(info,name)
goto 9999
endif
#if defined(HAVE_MOLD)
allocate(a%a,mold=b%a,stat=info)
allocate(b%a,mold=a%a,stat=info)
#else
call b%a%mold(a%a,info)
call a%a%mold(b%a,info)
#endif
if (info /= psb_success_) then
info = psb_err_alloc_dealloc_
goto 9999
end if
call a%a%transc(b%a)
call a%a%transc_2mat(b%a)
call psb_erractionrestore(err_act)
return

Loading…
Cancel
Save