Fixed checks to second smoother.

Fixed makefiles to include LINKOPT option *(empty by default)
Updated example new solver.
stopcriterion
Salvatore Filippone 8 years ago
parent e6c49efb9d
commit 9330489e6e

@ -4,6 +4,7 @@ include $(MLDINCDIR)/Make.inc.mld2p4
MLDLIBDIR=$(MLDDIR)/lib MLDLIBDIR=$(MLDDIR)/lib
MLD_LIBS=-L$(MLDLIBDIR) -lpsb_krylov -lmld_prec -lpsb_prec MLD_LIBS=-L$(MLDLIBDIR) -lpsb_krylov -lmld_prec -lpsb_prec
FINCLUDES=$(FMFLAG). $(FMFLAG)$(MLDINCDIR) $(PSBLAS_INCLUDES) $(FIFLAG). FINCLUDES=$(FMFLAG). $(FMFLAG)$(MLDINCDIR) $(PSBLAS_INCLUDES) $(FIFLAG).
LINKOPT=
DMOBJS=mld_dexample_ml.o data_input.o DMOBJS=mld_dexample_ml.o data_input.o
D1OBJS=mld_dexample_1lev.o data_input.o D1OBJS=mld_dexample_1lev.o data_input.o

@ -4,6 +4,7 @@ include $(MLDINCDIR)/Make.inc.mld2p4
MLDLIBDIR=$(MLDDIR)/lib MLDLIBDIR=$(MLDDIR)/lib
MLD_LIBS=-L$(MLDLIBDIR) -lpsb_krylov -lmld_prec -lpsb_prec MLD_LIBS=-L$(MLDLIBDIR) -lpsb_krylov -lmld_prec -lpsb_prec
FINCLUDES=$(FMFLAG). $(FMFLAG)$(MLDINCDIR) $(PSBLAS_INCLUDES) $(FIFLAG). FINCLUDES=$(FMFLAG). $(FMFLAG)$(MLDINCDIR) $(PSBLAS_INCLUDES) $(FIFLAG).
LINKOPT=
DMOBJS=mld_dexample_ml.o data_input.o DMOBJS=mld_dexample_ml.o data_input.o
D1OBJS=mld_dexample_1lev.o data_input.o D1OBJS=mld_dexample_1lev.o data_input.o

@ -68,7 +68,7 @@ subroutine mld_c_base_onelev_check(lv,info)
if (allocated(lv%sm2a)) then if (allocated(lv%sm2a)) then
call lv%sm2a%check(info) call lv%sm2a%check(info)
else else if (.not.inner_check(lv%sm2,lv%sm)) then
info=3111 info=3111
call psb_errpush(info,name) call psb_errpush(info,name)
goto 9999 goto 9999
@ -82,4 +82,14 @@ subroutine mld_c_base_onelev_check(lv,info)
9999 call psb_error_handler(err_act) 9999 call psb_error_handler(err_act)
return return
contains
function inner_check(smp,sm) result(res)
implicit none
logical :: res
class(mld_c_base_smoother_type), intent(in), pointer :: smp
class(mld_c_base_smoother_type), intent(in), target :: sm
res = associated(smp, sm)
end function inner_check
end subroutine mld_c_base_onelev_check end subroutine mld_c_base_onelev_check

@ -68,7 +68,7 @@ subroutine mld_d_base_onelev_check(lv,info)
if (allocated(lv%sm2a)) then if (allocated(lv%sm2a)) then
call lv%sm2a%check(info) call lv%sm2a%check(info)
else else if (.not.inner_check(lv%sm2,lv%sm)) then
info=3111 info=3111
call psb_errpush(info,name) call psb_errpush(info,name)
goto 9999 goto 9999
@ -82,4 +82,14 @@ subroutine mld_d_base_onelev_check(lv,info)
9999 call psb_error_handler(err_act) 9999 call psb_error_handler(err_act)
return return
contains
function inner_check(smp,sm) result(res)
implicit none
logical :: res
class(mld_d_base_smoother_type), intent(in), pointer :: smp
class(mld_d_base_smoother_type), intent(in), target :: sm
res = associated(smp, sm)
end function inner_check
end subroutine mld_d_base_onelev_check end subroutine mld_d_base_onelev_check

@ -68,7 +68,7 @@ subroutine mld_s_base_onelev_check(lv,info)
if (allocated(lv%sm2a)) then if (allocated(lv%sm2a)) then
call lv%sm2a%check(info) call lv%sm2a%check(info)
else else if (.not.inner_check(lv%sm2,lv%sm)) then
info=3111 info=3111
call psb_errpush(info,name) call psb_errpush(info,name)
goto 9999 goto 9999
@ -82,4 +82,14 @@ subroutine mld_s_base_onelev_check(lv,info)
9999 call psb_error_handler(err_act) 9999 call psb_error_handler(err_act)
return return
contains
function inner_check(smp,sm) result(res)
implicit none
logical :: res
class(mld_s_base_smoother_type), intent(in), pointer :: smp
class(mld_s_base_smoother_type), intent(in), target :: sm
res = associated(smp, sm)
end function inner_check
end subroutine mld_s_base_onelev_check end subroutine mld_s_base_onelev_check

@ -68,7 +68,7 @@ subroutine mld_z_base_onelev_check(lv,info)
if (allocated(lv%sm2a)) then if (allocated(lv%sm2a)) then
call lv%sm2a%check(info) call lv%sm2a%check(info)
else else if (.not.inner_check(lv%sm2,lv%sm)) then
info=3111 info=3111
call psb_errpush(info,name) call psb_errpush(info,name)
goto 9999 goto 9999
@ -82,4 +82,14 @@ subroutine mld_z_base_onelev_check(lv,info)
9999 call psb_error_handler(err_act) 9999 call psb_error_handler(err_act)
return return
contains
function inner_check(smp,sm) result(res)
implicit none
logical :: res
class(mld_z_base_smoother_type), intent(in), pointer :: smp
class(mld_z_base_smoother_type), intent(in), target :: sm
res = associated(smp, sm)
end function inner_check
end subroutine mld_z_base_onelev_check end subroutine mld_z_base_onelev_check

@ -9,6 +9,7 @@ DFSOBJS=mld_df_sample.o data_input.o
SFSOBJS=mld_sf_sample.o data_input.o SFSOBJS=mld_sf_sample.o data_input.o
CFSOBJS=mld_cf_sample.o data_input.o CFSOBJS=mld_cf_sample.o data_input.o
ZFSOBJS=mld_zf_sample.o data_input.o ZFSOBJS=mld_zf_sample.o data_input.o
LINKOPT=
EXEDIR=./runs EXEDIR=./runs

@ -8,12 +8,13 @@ FINCLUDES=$(FMFLAG). $(FMFLAG)$(MLDINCDIR) $(PSBLAS_INCLUDES) $(FIFLAG).
PD3DOBJS=mld_pde3d_newslv.o data_input.o mld_d_tlu_solver.o mld_d_tlu_solver_impl.o PD3DOBJS=mld_pde3d_newslv.o data_input.o mld_d_tlu_solver.o mld_d_tlu_solver_impl.o
PSOBJS=spde.o data_input.o PSOBJS=spde.o data_input.o
EXEDIR=./runs EXEDIR=./runs
LINKOPT=
all: mld_pde3d_newslv all: mld_pde3d_newslv
mld_pde3d_newslv: $(PD3DOBJS) mld_pde3d_newslv: $(PD3DOBJS)
$(FLINK) $(PD3DOBJS) -o mld_pde3d_newslv $(MLD_LIBS) $(PSBLAS_LIBS) $(LDLIBS) $(FLINK) $(LINKOPT) $(PD3DOBJS) -o mld_pde3d_newslv $(MLD_LIBS) $(PSBLAS_LIBS) $(LDLIBS)
/bin/mv mld_pde3d_newslv $(EXEDIR) /bin/mv mld_pde3d_newslv $(EXEDIR)

@ -99,6 +99,7 @@ module mld_d_tlu_solver
!procedure, pass(sv) :: csetr => d_tlu_solver_csetr !procedure, pass(sv) :: csetr => d_tlu_solver_csetr
!procedure, pass(sv) :: sizeof => d_tlu_solver_sizeof !procedure, pass(sv) :: sizeof => d_tlu_solver_sizeof
!procedure, pass(sv) :: get_nzeros => d_tlu_solver_get_nzeros !procedure, pass(sv) :: get_nzeros => d_tlu_solver_get_nzeros
!procedure, nopass :: get_id => d_tlu_solver_get_id
! !
@ -109,11 +110,10 @@ module mld_d_tlu_solver
procedure, pass(sv) :: default => d_tlu_solver_default procedure, pass(sv) :: default => d_tlu_solver_default
procedure, pass(sv) :: build => mld_d_tlu_solver_bld procedure, pass(sv) :: build => mld_d_tlu_solver_bld
procedure, nopass :: get_fmt => d_tlu_solver_get_fmt procedure, nopass :: get_fmt => d_tlu_solver_get_fmt
procedure, nopass :: get_id => d_tlu_solver_get_id
end type mld_d_tlu_solver_type end type mld_d_tlu_solver_type
private :: d_tlu_solver_get_fmt, d_tlu_solver_get_id private :: d_tlu_solver_get_fmt, d_tlu_solver_descr, d_tlu_solver_default
interface interface
subroutine mld_d_tlu_solver_bld(a,desc_a,sv,info,b,amold,vmold, imold) subroutine mld_d_tlu_solver_bld(a,desc_a,sv,info,b,amold,vmold, imold)
@ -159,13 +159,6 @@ contains
val = "TLU solver" val = "TLU solver"
end function d_tlu_solver_get_fmt end function d_tlu_solver_get_fmt
function d_tlu_solver_get_id() result(val)
implicit none
integer(psb_ipk_) :: val
val = mld_ilu_n_
end function d_tlu_solver_get_id
subroutine d_tlu_solver_descr(sv,info,iout,coarse) subroutine d_tlu_solver_descr(sv,info,iout,coarse)
Implicit None Implicit None

Loading…
Cancel
Save