Here are the instances you need to replace:
$ grep -n "CALL DSOLVE\(.*\)" ~/fortran/odr.f
9932: CALL DSOLVE(NQ,OMEGA,NQ,WRK1(I,1:NQ,J),4)
9933: CALL DSOLVE(NQ,OMEGA,NQ,WRK1(I,1:NQ,J),2)
9940: CALL DSOLVE(M,WRK4,M,WRK5,4)
9941: CALL DSOLVE(M,WRK4,M,WRK5,2)
9948: CALL DSOLVE(NQ,OMEGA,NQ,TFJACB(I,1:NQ,K),4)
9968: CALL DSOLVE(NQ,OMEGA,NQ,WRK2(I,1:NQ),4)
10109: CALL DSOLVE(M,WRK4,M,WRK5,4)
10110: CALL DSOLVE(M,WRK4,M,WRK5,2)
10129: CALL DSOLVE(M,WRK4,M,T(I,1:M),4)
10130: CALL DSOLVE(M,WRK4,M,T(I,1:M),2)
11621: CALL DSOLVE(M,E,LDE,WRK5,4)
The job
argument (argument 5 of dsolve
) is either 2 or 4, corresponding to the operations:
C 2 Solve T*X=B, T upper triangular,
C 4 Solve trans(T)*X=B, T upper triangular.
The corresponding BLAS calls would be
! Old
call dsolve(n,t,ldt,b,job)
! New
call dtrsv('U','N','N',n,t,ldt,b,1) ! JOB = 2 -> Upper-triangular, Notranspose, Nonunit-diagonal
call dtrsv('U','T','N',n,t,ldt,b,1) ! JOB = 4 -> Upper-triangular, Transpose, Nonunit-diagonal