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

--- Comment #2 from Joost VandeVondele <Joost.VandeVondele at mat dot ethz.ch> 
---
this testcase gives the same error without LTO. Just -O2 is sufficient:

  INTEGER, PARAMETER :: dp = 8
  REAL(KIND=dp), VOLATILE :: r=0.1_dp
  r = expint(1,r)
CONTAINS
  FUNCTION expint(n,x)
    REAL(dp) :: x, expint
    INTEGER :: maxit=100 
    nm1=n-1
    DO i=1,MAXIT
      IF(i.NE.nm1) THEN
        DO ii=1,nm1
          psi=psi+1.0_dp/ii
        END DO
        del=fact*(-LOG(x)+psi)
      END IF
      expint=expint+del
    END DO
  END FUNCTION expint
END

Reply via email to