[Bug fortran/23318] program works correctly with -g option but fails with -O option on LINUX

kargl at gcc dot gnu dot org gcc-bugzilla@gcc.gnu.org
Wed Aug 10 20:19:00 GMT 2005


------- Additional Comments From kargl at gcc dot gnu dot org  2005-08-10 20:19 -------
I suggest running the code through ftnchek and fixing potential
problems.  These looks suspicious

Warning in module MAIN in file show_bug.f: Variables used before set
    IDATWR used at line 15 file show_bug.f; never set
    N1 used at line 18 file show_bug.f; never set

Warning: Common block ISUBST Elements used but never set:
    NSUBST

Warning: Common block ADINAI Elements used but never set:
    TSTART

Warning: Subprogram TIMFUN argument data type mismatch at position 2:
    Dummy arg IPNT in module TIMFUN line 35 file show_bug.f is type intg
    Actual arg A(N1) in module MAIN line 24 file show_bug.f is type real*8

Warning: Subprogram TIMFUN argument arrayness mismatch at position 1:
    Dummy arg RGST in module TIMFUN line 35 file show_bug.f is whole array
    Actual arg A(M5) in module MAIN line 24 file show_bug.f is array element
  and at position 2:
    Dummy arg IPNT in module TIMFUN line 35 file show_bug.f is whole array
    Actual arg A(N1) in module MAIN line 24 file show_bug.f is array element
  and at position 3:
    Dummy arg TIMV in module TIMFUN line 35 file show_bug.f is whole array
    Actual arg A(M2) in module MAIN line 24 file show_bug.f is array element

Warning: Subprogram TIMFUN argument usage mismatch at position 1:
    Dummy arg RGST in module TIMFUN line 35 file show_bug.f is modified
    Actual arg A(M5) in module MAIN line 24 file show_bug.f may be same as arg 
 5: A(M4)
  and at position 2:
    Dummy arg IPNT in module TIMFUN line 35 file show_bug.f is modified
    Actual arg A(N1) in module MAIN line 24 file show_bug.f may be same as arg 
 1: A(M5)
  and at position 3:
    Dummy arg TIMV in module TIMFUN line 35 file show_bug.f is modified
    Actual arg A(M2) in module MAIN line 24 file show_bug.f may be same as arg 
 2: A(N1)



-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=23318



More information about the Gcc-bugs mailing list