mirror of
https://github.com/sfilippone/amg4psblas.git
synced 2026-10-06 14:44:55 +00:00
Fix message in samples
This commit is contained in:
@@ -11,16 +11,16 @@ module amg_dprec_cbind_mod
|
||||
contains
|
||||
|
||||
#if 1
|
||||
#define MLDC_DEBUG(MSG) write(*,*) __FILE__,':',__LINE__,':',MSG
|
||||
#define MLDC_ERROR(MSG) write(*,*) __FILE__,':',__LINE__,':'," ERROR: ",MSG
|
||||
#define AMGC_DEBUG(MSG) write(*,*) __FILE__,':',__LINE__,':',MSG
|
||||
#define AMGC_ERROR(MSG) write(*,*) __FILE__,':',__LINE__,':'," ERROR: ",MSG
|
||||
#else
|
||||
#define MLDC_DEBUG(MSG)
|
||||
#define MLDC_ERROR(MSG)
|
||||
#define AMGC_DEBUG(MSG)
|
||||
#define AMGC_ERROR(MSG)
|
||||
#endif
|
||||
#define amg_success_ 0
|
||||
!#define MLDC_ERR_FILTER(INFO) min(0,INFO)
|
||||
#define MLDC_ERR_FILTER(INFO) (INFO)
|
||||
#define MLDC_ERR_HANDLE(INFO) if(INFO/=amg_success_)MLDC_ERROR("ERROR!")
|
||||
!#define AMGC_ERR_FILTER(INFO) min(0,INFO)
|
||||
#define AMGC_ERR_FILTER(INFO) (INFO)
|
||||
#define AMGC_ERR_HANDLE(INFO) if(INFO/=amg_success_)AMGC_ERROR("ERROR!")
|
||||
function amg_c_dprecinit(cctxt,ph,ptype) bind(c) result(res)
|
||||
implicit none
|
||||
|
||||
@@ -47,8 +47,8 @@ contains
|
||||
|
||||
call precp%init(psb_c2f_ctxt(cctxt),fptype,iret)
|
||||
|
||||
res = MLDC_ERR_FILTER(iret)
|
||||
MLDC_ERR_HANDLE(res)
|
||||
res = AMGC_ERR_FILTER(iret)
|
||||
AMGC_ERR_HANDLE(res)
|
||||
return
|
||||
end function amg_c_dprecinit
|
||||
|
||||
@@ -74,8 +74,8 @@ contains
|
||||
|
||||
call precp%set(fwhat,val,iret)
|
||||
|
||||
res = MLDC_ERR_FILTER(iret)
|
||||
MLDC_ERR_HANDLE(res)
|
||||
res = AMGC_ERR_FILTER(iret)
|
||||
AMGC_ERR_HANDLE(res)
|
||||
return
|
||||
end function amg_c_dprecseti
|
||||
|
||||
@@ -102,8 +102,8 @@ contains
|
||||
|
||||
call precp%set(fwhat,val,iret)
|
||||
|
||||
res = MLDC_ERR_FILTER(iret)
|
||||
MLDC_ERR_HANDLE(res)
|
||||
res = AMGC_ERR_FILTER(iret)
|
||||
AMGC_ERR_HANDLE(res)
|
||||
return
|
||||
end function amg_c_dprecsetr
|
||||
|
||||
@@ -129,8 +129,8 @@ contains
|
||||
|
||||
call precp%set(fwhat,fval,iret)
|
||||
|
||||
res = MLDC_ERR_FILTER(iret)
|
||||
MLDC_ERR_HANDLE(res)
|
||||
res = AMGC_ERR_FILTER(iret)
|
||||
AMGC_ERR_HANDLE(res)
|
||||
return
|
||||
end function amg_c_dprecsetc
|
||||
|
||||
@@ -165,8 +165,8 @@ contains
|
||||
|
||||
call amg_precbld(ap,descp,precp,iret)
|
||||
|
||||
res = MLDC_ERR_FILTER(iret)
|
||||
MLDC_ERR_HANDLE(res)
|
||||
res = AMGC_ERR_FILTER(iret)
|
||||
AMGC_ERR_HANDLE(res)
|
||||
|
||||
return
|
||||
end function amg_c_dprecbld
|
||||
@@ -202,8 +202,8 @@ contains
|
||||
|
||||
call precp%hierarchy_build(ap,descp,iret)
|
||||
|
||||
res = MLDC_ERR_FILTER(iret)
|
||||
MLDC_ERR_HANDLE(res)
|
||||
res = AMGC_ERR_FILTER(iret)
|
||||
AMGC_ERR_HANDLE(res)
|
||||
|
||||
return
|
||||
end function amg_c_dhierarchy_build
|
||||
@@ -239,8 +239,8 @@ contains
|
||||
|
||||
call precp%smoothers_build(ap,descp,iret)
|
||||
|
||||
res = MLDC_ERR_FILTER(iret)
|
||||
MLDC_ERR_HANDLE(res)
|
||||
res = AMGC_ERR_FILTER(iret)
|
||||
AMGC_ERR_HANDLE(res)
|
||||
|
||||
return
|
||||
end function amg_c_dsmoothers_build
|
||||
@@ -353,8 +353,8 @@ contains
|
||||
|
||||
call precp%smoothers_build(ap,descp,iret,amold=amold,vmold=vmold,imold=imold)
|
||||
|
||||
res = MLDC_ERR_FILTER(iret)
|
||||
MLDC_ERR_HANDLE(res)
|
||||
res = AMGC_ERR_FILTER(iret)
|
||||
AMGC_ERR_HANDLE(res)
|
||||
|
||||
return
|
||||
end function amg_c_dsmoothers_build_opt
|
||||
@@ -494,8 +494,8 @@ contains
|
||||
call precp%apply(bp,xp,descp,info)
|
||||
|
||||
! Error handling and return
|
||||
res = MLDC_ERR_FILTER(info)
|
||||
MLDC_ERR_HANDLE(res)
|
||||
res = AMGC_ERR_FILTER(info)
|
||||
AMGC_ERR_HANDLE(res)
|
||||
return
|
||||
end function amg_c_dprecapply
|
||||
|
||||
@@ -550,8 +550,8 @@ end function amg_c_dprecapply
|
||||
call precp%apply(bp,xp,descp,info,trans=ftrans)
|
||||
|
||||
! Error handling and return
|
||||
res = MLDC_ERR_FILTER(info)
|
||||
MLDC_ERR_HANDLE(res)
|
||||
res = AMGC_ERR_FILTER(info)
|
||||
AMGC_ERR_HANDLE(res)
|
||||
return
|
||||
end function amg_c_dprecapply_opt
|
||||
|
||||
@@ -574,8 +574,8 @@ end function amg_c_dprecapply_opt
|
||||
|
||||
call precp%free(iret)
|
||||
|
||||
res = MLDC_ERR_FILTER(iret)
|
||||
MLDC_ERR_HANDLE(res)
|
||||
res = AMGC_ERR_FILTER(iret)
|
||||
AMGC_ERR_HANDLE(res)
|
||||
return
|
||||
end function amg_c_dprecfree
|
||||
|
||||
@@ -600,8 +600,8 @@ end function amg_c_dprecapply_opt
|
||||
call flush(psb_out_unit)
|
||||
|
||||
iret = 0
|
||||
res = MLDC_ERR_FILTER(iret)
|
||||
MLDC_ERR_HANDLE(res)
|
||||
res = AMGC_ERR_FILTER(iret)
|
||||
AMGC_ERR_HANDLE(res)
|
||||
return
|
||||
end function amg_c_ddescr
|
||||
|
||||
@@ -650,8 +650,8 @@ end function amg_c_dprecapply_opt
|
||||
|
||||
iret = info
|
||||
|
||||
res = MLDC_ERR_FILTER(iret)
|
||||
MLDC_ERR_HANDLE(res)
|
||||
res = AMGC_ERR_FILTER(iret)
|
||||
AMGC_ERR_HANDLE(res)
|
||||
return
|
||||
|
||||
end function amg_c_dallocate_wrk
|
||||
|
||||
@@ -11,16 +11,16 @@ module amg_zprec_cbind_mod
|
||||
contains
|
||||
|
||||
#if 1
|
||||
#define MLDC_DEBUG(MSG) write(*,*) __FILE__,':',__LINE__,':',MSG
|
||||
#define MLDC_ERROR(MSG) write(*,*) __FILE__,':',__LINE__,':'," ERROR: ",MSG
|
||||
#define AMGC_DEBUG(MSG) write(*,*) __FILE__,':',__LINE__,':',MSG
|
||||
#define AMGC_ERROR(MSG) write(*,*) __FILE__,':',__LINE__,':'," ERROR: ",MSG
|
||||
#else
|
||||
#define MLDC_DEBUG(MSG)
|
||||
#define MLDC_ERROR(MSG)
|
||||
#define AMGC_DEBUG(MSG)
|
||||
#define AMGC_ERROR(MSG)
|
||||
#endif
|
||||
#define amg_success_ 0
|
||||
!#define MLDC_ERR_FILTER(INFO) min(0,INFO)
|
||||
#define MLDC_ERR_FILTER(INFO) (INFO)
|
||||
#define MLDC_ERR_HANDLE(INFO) if(INFO/=amg_success_)MLDC_ERROR("ERROR!")
|
||||
!#define AMGC_ERR_FILTER(INFO) min(0,INFO)
|
||||
#define AMGC_ERR_FILTER(INFO) (INFO)
|
||||
#define AMGC_ERR_HANDLE(INFO) if(INFO/=amg_success_)AMGC_ERROR("ERROR!")
|
||||
|
||||
function amg_c_zprecinit(cctxt,ph,ptype) bind(c) result(res)
|
||||
implicit none
|
||||
@@ -48,8 +48,8 @@ contains
|
||||
|
||||
call precp%init(psb_c2f_ctxt(cctxt),fptype,iret)
|
||||
|
||||
res = MLDC_ERR_FILTER(iret)
|
||||
MLDC_ERR_HANDLE(res)
|
||||
res = AMGC_ERR_FILTER(iret)
|
||||
AMGC_ERR_HANDLE(res)
|
||||
return
|
||||
end function amg_c_zprecinit
|
||||
|
||||
@@ -75,8 +75,8 @@ contains
|
||||
|
||||
call precp%set(fwhat,val,iret)
|
||||
|
||||
res = MLDC_ERR_FILTER(iret)
|
||||
MLDC_ERR_HANDLE(res)
|
||||
res = AMGC_ERR_FILTER(iret)
|
||||
AMGC_ERR_HANDLE(res)
|
||||
return
|
||||
end function amg_c_zprecseti
|
||||
|
||||
@@ -103,8 +103,8 @@ contains
|
||||
|
||||
call precp%set(fwhat,val,iret)
|
||||
|
||||
res = MLDC_ERR_FILTER(iret)
|
||||
MLDC_ERR_HANDLE(res)
|
||||
res = AMGC_ERR_FILTER(iret)
|
||||
AMGC_ERR_HANDLE(res)
|
||||
return
|
||||
end function amg_c_zprecsetr
|
||||
|
||||
@@ -130,8 +130,8 @@ contains
|
||||
|
||||
call precp%set(fwhat,fval,iret)
|
||||
|
||||
res = MLDC_ERR_FILTER(iret)
|
||||
MLDC_ERR_HANDLE(res)
|
||||
res = AMGC_ERR_FILTER(iret)
|
||||
AMGC_ERR_HANDLE(res)
|
||||
return
|
||||
end function amg_c_zprecsetc
|
||||
|
||||
@@ -166,8 +166,8 @@ contains
|
||||
|
||||
call amg_precbld(ap,descp,precp,iret)
|
||||
|
||||
res = MLDC_ERR_FILTER(iret)
|
||||
MLDC_ERR_HANDLE(res)
|
||||
res = AMGC_ERR_FILTER(iret)
|
||||
AMGC_ERR_HANDLE(res)
|
||||
|
||||
return
|
||||
end function amg_c_zprecbld
|
||||
@@ -203,8 +203,8 @@ contains
|
||||
|
||||
call precp%hierarchy_build(ap,descp,iret)
|
||||
|
||||
res = MLDC_ERR_FILTER(iret)
|
||||
MLDC_ERR_HANDLE(res)
|
||||
res = AMGC_ERR_FILTER(iret)
|
||||
AMGC_ERR_HANDLE(res)
|
||||
|
||||
return
|
||||
end function amg_c_zhierarchy_build
|
||||
@@ -240,8 +240,8 @@ contains
|
||||
|
||||
call precp%smoothers_build(ap,descp,iret)
|
||||
|
||||
res = MLDC_ERR_FILTER(iret)
|
||||
MLDC_ERR_HANDLE(res)
|
||||
res = AMGC_ERR_FILTER(iret)
|
||||
AMGC_ERR_HANDLE(res)
|
||||
|
||||
return
|
||||
end function amg_c_zsmoothers_build
|
||||
@@ -348,8 +348,8 @@ contains
|
||||
|
||||
call precp%smoothers_build(ap,descp,iret,amold=amold,vmold=vmold,imold=imold)
|
||||
|
||||
res = MLDC_ERR_FILTER(iret)
|
||||
MLDC_ERR_HANDLE(res)
|
||||
res = AMGC_ERR_FILTER(iret)
|
||||
AMGC_ERR_HANDLE(res)
|
||||
|
||||
return
|
||||
end function amg_c_zsmoothers_build_format
|
||||
@@ -484,8 +484,8 @@ contains
|
||||
call precp%apply(bp,xp,descp,info)
|
||||
|
||||
! Error handling and return
|
||||
res = MLDC_ERR_FILTER(info)
|
||||
MLDC_ERR_HANDLE(res)
|
||||
res = AMGC_ERR_FILTER(info)
|
||||
AMGC_ERR_HANDLE(res)
|
||||
return
|
||||
end function amg_c_zprecapply
|
||||
|
||||
@@ -540,8 +540,8 @@ contains
|
||||
call precp%apply(bp,xp,descp,info,trans=ftrans)
|
||||
|
||||
! Error handling and return
|
||||
res = MLDC_ERR_FILTER(info)
|
||||
MLDC_ERR_HANDLE(res)
|
||||
res = AMGC_ERR_FILTER(info)
|
||||
AMGC_ERR_HANDLE(res)
|
||||
return
|
||||
end function amg_c_zprecapply_opt
|
||||
|
||||
@@ -564,8 +564,8 @@ contains
|
||||
|
||||
call precp%free(iret)
|
||||
|
||||
res = MLDC_ERR_FILTER(iret)
|
||||
MLDC_ERR_HANDLE(res)
|
||||
res = AMGC_ERR_FILTER(iret)
|
||||
AMGC_ERR_HANDLE(res)
|
||||
return
|
||||
end function amg_c_zprecfree
|
||||
|
||||
@@ -590,8 +590,8 @@ contains
|
||||
call flush(psb_out_unit)
|
||||
|
||||
iret = 0
|
||||
res = MLDC_ERR_FILTER(iret)
|
||||
MLDC_ERR_HANDLE(res)
|
||||
res = AMGC_ERR_FILTER(iret)
|
||||
AMGC_ERR_HANDLE(res)
|
||||
return
|
||||
end function amg_c_zdescr
|
||||
|
||||
@@ -640,8 +640,8 @@ contains
|
||||
|
||||
iret = info
|
||||
|
||||
res = MLDC_ERR_FILTER(iret)
|
||||
MLDC_ERR_HANDLE(res)
|
||||
res = AMGC_ERR_FILTER(iret)
|
||||
AMGC_ERR_HANDLE(res)
|
||||
return
|
||||
|
||||
end function amg_c_zallocate_wrk
|
||||
|
||||
@@ -187,7 +187,7 @@ program amg_cf_sample
|
||||
!
|
||||
if (iam == psb_root_) then
|
||||
write(psb_out_unit,*) ' '
|
||||
write(psb_out_unit,*) 'Welcome to MLD2P4 version: ',amg_version_string_
|
||||
write(psb_out_unit,*) 'Welcome to AMG4PSBLAS version: ',amg_version_string_
|
||||
write(psb_out_unit,*) 'This is the ',trim(name),' sample test program'
|
||||
write(psb_out_unit,*) ' '
|
||||
end if
|
||||
|
||||
@@ -187,7 +187,7 @@ program amg_df_sample
|
||||
!
|
||||
if (iam == psb_root_) then
|
||||
write(psb_out_unit,*) ' '
|
||||
write(psb_out_unit,*) 'Welcome to MLD2P4 version: ',amg_version_string_
|
||||
write(psb_out_unit,*) 'Welcome to AMG4PSBLAS version: ',amg_version_string_
|
||||
write(psb_out_unit,*) 'This is the ',trim(name),' sample test program'
|
||||
write(psb_out_unit,*) ' '
|
||||
end if
|
||||
|
||||
@@ -187,7 +187,7 @@ program amg_sf_sample
|
||||
!
|
||||
if (iam == psb_root_) then
|
||||
write(psb_out_unit,*) ' '
|
||||
write(psb_out_unit,*) 'Welcome to MLD2P4 version: ',amg_version_string_
|
||||
write(psb_out_unit,*) 'Welcome to AMG4PSBLAS version: ',amg_version_string_
|
||||
write(psb_out_unit,*) 'This is the ',trim(name),' sample test program'
|
||||
write(psb_out_unit,*) ' '
|
||||
end if
|
||||
|
||||
@@ -187,7 +187,7 @@ program amg_zf_sample
|
||||
!
|
||||
if (iam == psb_root_) then
|
||||
write(psb_out_unit,*) ' '
|
||||
write(psb_out_unit,*) 'Welcome to MLD2P4 version: ',amg_version_string_
|
||||
write(psb_out_unit,*) 'Welcome to AMG4PSBLAS version: ',amg_version_string_
|
||||
write(psb_out_unit,*) 'This is the ',trim(name),' sample test program'
|
||||
write(psb_out_unit,*) ' '
|
||||
end if
|
||||
|
||||
Reference in New Issue
Block a user