PGI User Forum
 SearchSearch   MemberlistMemberlist     RegisterRegister   ProfileProfile    Log inLog in 

CUDA-x86.

Why does PVF slow than IVF while reading ascii file?
Goto page 1, 2  Next
 
Post new topic   Reply to topic    PGI User Forum Forum Index -> Debugging and Profiling
View previous topic :: View next topic  
Author Message
cyFeng



Joined: 05 Mar 2010
Posts: 17

PostPosted: Fri May 27, 2011 9:13 pm    Post subject: Why does PVF slow than IVF while reading ascii file? Reply with quote

Hi, All

I happened to find that reading the same ascii file using the execution compiled by PVF 10.9 spent 10.76 seconds.
However, using the execution compiled by IVF 11.1.065 (the same source code) spent just 1.6 seconds.
The platform is Windows XP 32-bit.
The ascii file is about 25.2 Mb and the main source code is the following...
Do I do something wrong?

Code:

    do j=1, 67600
        read(fid,'(A3,A6,1X,A2)',advance='no') Y_TYPE, ID, REG_MESSAGE
        if (REG_MESSAGE == 'ER') then
            read(fid,*)
            WX_Est(n_eqn)%OMP_P_Eqn(j)%Nx=0
            allocate( WX_Est(n_eqn)%OMP_P_Eqn(j)%COEF(1) )
            WX_Est(n_eqn)%OMP_P_Eqn(j)%COEF(1)=-9999.
            cycle
        else
            read(fid,'(I3)',advance='no') WX_Est(n_eqn)%OMP_P_Eqn(j)%Nx
            allocate(WX_Est(n_eqn)%OMP_P_Eqn(j)%COEF(WX_Est(n_eqn)%OMP_P_Eqn(j)%Nx+1))
            allocate(WX_Est(n_eqn)%OMP_P_Eqn(j)%CODE(WX_Est(n_eqn)%OMP_P_Eqn(j)%Nx) )
            write(S_FORMAT,'(A4,I2,A12,I2,A8)')"(1X,",WX_Est(n_eqn)%OMP_P_Eqn(j)%Nx+1,"(ES15.8,1x),",&
                  &WX_Est(n_eqn)%OMP_P_Eqn(j)%Nx,"(A8,1x))"
            read(fid,trim(S_FORMAT))WX_Est(n_eqn)%OMP_P_Eqn(j)%COEF(k),&
                  &k=1,WX_Est(n_eqn)%OMP_P_Eqn(j)%NX+1),&
                  &WX_Est(n_eqn)%OMP_P_Eqn(j)%CODE(k),&
                  &k=1,WX_Est(n_eqn)%OMP_P_Eqn(j)%NX)
            do k=1,WX_Est(n_eqn)%OMP_P_Eqn(j)%NX
                WX_Est(n_eqn)%OMP_P_Eqn(j)%CODE(k)=&
                &adjustl(WX_Est(n_eqn)%OMP_P_Eqn(j)%CODE(k))
            end do
        end if
    end do
Back to top
View user's profile
mkcolg



Joined: 30 Jun 2004
Posts: 6142
Location: The Portland Group Inc.

PostPosted: Wed Jun 01, 2011 4:16 pm    Post subject: Reply with quote

Hi cyFeng,

Unfortunately, we can't tell without a reproducing example. Can you send a test case to PGI Customer Service (trs@pgroup.com)?

Though, one thing to try is replace your format strings with FORMAT statements. i.e.

read(fid,'(A3,A6,1X,A2)',advance='no') ...
becomes
read(fid,97,advance='no') ...
97 format(A3,A6,1X,A2)

read(fid,'(I3)',advance='no') ...
becomes
read(fid,98,advance='no') ...
98 format(A3,A6,1X,A2)

write(S_FORMAT,'(A4,I2,A12,I2,A8)') ...
becomes
write(S_FORMAT,99) ...
99 format(A3,A6,1X,A2

Thanks,
Mat
Back to top
View user's profile
cyFeng



Joined: 05 Mar 2010
Posts: 17

PostPosted: Thu Jun 02, 2011 8:38 am    Post subject: Reply with quote

Hi Mat,

I tried your suggestion. But...in vain
The test case have been sent to trs@pgroup.com. (titled "test case for Mat")
Thank you for the kind help.

cyFeng
Back to top
View user's profile
mkcolg



Joined: 30 Jun 2004
Posts: 6142
Location: The Portland Group Inc.

PostPosted: Fri Jun 03, 2011 1:44 pm    Post subject: Reply with quote

Hi cyFeng,

I was able to recreate your issue and have sent a report to our engineers for further investigation (TRS#17898).

Most the time is spent in the Microsoft system libraries. We're not sure how much control we'll have in speeding these routines up, but we will make our best effort.

Thanks for bringing this issue to our attention,
Mat
Back to top
View user's profile
cyFeng



Joined: 05 Mar 2010
Posts: 17

PostPosted: Tue Jun 07, 2011 9:35 pm    Post subject: Reply with quote

Hi Mat,

Thanks for your help.
BTW, will it be improved soon..?
Back to top
View user's profile
Display posts from previous:   
Post new topic   Reply to topic    PGI User Forum Forum Index -> Debugging and Profiling All times are GMT - 7 Hours
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © phpBB Group