Fix test/hello programs

pizdaint-runs
Salvatore Filippone 5 years ago
parent 1a442ec7d0
commit b8f66ef607

@ -4,7 +4,7 @@ MODDIR=$(BASEDIR)/modules/
include $(INCDIR)/Make.inc.psblas
#
# Libraries used
LIBDIR=$(INSTALLDIR)/lib
LIBDIR=$(BASEDIR)/lib
PSBLAS_LIB= -L$(LIBDIR) -lpsb_util -lpsb_krylov -lpsb_prec -lpsb_base
LDLIBS=$(PSBLDLIBS)
#

@ -1,7 +1,7 @@
program hello
use psb_base_mod
implicit none
integer iam, np, icontxt, ip, jp, idummy
integer(psb_ipk_) :: iam, np, icontxt, ip, jp, idummy
call psb_init(icontxt)
call psb_info(icontxt,iam,np)
@ -14,7 +14,8 @@ program hello
write(*,*) 'Hello, world: all ',np, &
& ' processes checked in!'
else
call psb_snd(icontxt,idummy,0)
ip = 0
call psb_snd(icontxt,idummy,ip)
endif
end if
call psb_exit(icontxt)

@ -19,7 +19,8 @@ program pingpong
write(*,*) 'Hello, world: all ',np, &
& ' processes checked in!'
else
call psb_snd(icontxt,idummy,0)
ip = 0
call psb_snd(icontxt,idummy,ip)
endif
end if
@ -27,9 +28,10 @@ program pingpong
call psb_barrier(icontxt)
if (iam == 0) then
do i=1, 16
ip = 1
t0 = psb_wtime()
call psb_snd(icontxt,v(1:n),1)
call psb_rcv(icontxt,v(1:n),1)
call psb_snd(icontxt,v(1:n),ip)
call psb_rcv(icontxt,v(1:n),ip)
t1 = psb_wtime()
bytes = done*n*psb_sizeof_dp
mbs = 2.d0*(bytes/(t1-t0))*1.d-6
@ -38,8 +40,9 @@ program pingpong
end do
else if (iam == 1) then
do i=1, 16
call psb_rcv(icontxt,v(1:n),0)
call psb_snd(icontxt,v(1:n),0)
ip = 0
call psb_rcv(icontxt,v(1:n),ip)
call psb_snd(icontxt,v(1:n),ip)
n = n * 2
end do
end if

@ -1,4 +1,4 @@
PRESSMAT1.mtx
pde100.mtx
MM
0

Loading…
Cancel
Save