|
|
|
|
@ -253,6 +253,40 @@ contains
|
|
|
|
|
end function psb_c_cgefree
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
function psb_c_cgereinit(xh,cdh,clear) bind(c) result(res)
|
|
|
|
|
|
|
|
|
|
implicit none
|
|
|
|
|
integer(psb_c_ipk_) :: res
|
|
|
|
|
type(psb_c_cvector) :: xh
|
|
|
|
|
type(psb_c_descriptor) :: cdh
|
|
|
|
|
logical(c_bool), value :: clear
|
|
|
|
|
|
|
|
|
|
type(psb_desc_type), pointer :: descp
|
|
|
|
|
type(psb_c_vect_type), pointer :: xp
|
|
|
|
|
integer(psb_c_ipk_) :: info
|
|
|
|
|
logical :: fclear
|
|
|
|
|
|
|
|
|
|
res = -1
|
|
|
|
|
|
|
|
|
|
if (c_associated(cdh%item)) then
|
|
|
|
|
call c_f_pointer(cdh%item,descp)
|
|
|
|
|
else
|
|
|
|
|
return
|
|
|
|
|
end if
|
|
|
|
|
if (c_associated(xh%item)) then
|
|
|
|
|
call c_f_pointer(xh%item,xp)
|
|
|
|
|
else
|
|
|
|
|
return
|
|
|
|
|
end if
|
|
|
|
|
|
|
|
|
|
fclear = clear
|
|
|
|
|
call xp%reinit(info, clear=fclear)
|
|
|
|
|
res = min(0,info)
|
|
|
|
|
|
|
|
|
|
return
|
|
|
|
|
end function psb_c_cgereinit
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
function psb_c_cgeins(nz,irw,val,xh,cdh) bind(c) result(res)
|
|
|
|
|
|
|
|
|
|
implicit none
|
|
|
|
|
|