This is the mail archive of the
fortran@gcc.gnu.org
mailing list for the GNU Fortran project.
Re: wrong code with -fforce-addr
On Wed, Aug 29, 2007 at 07:45:31PM +0200, Manfred Schwarb wrote:
>
> SUBROUTINE FI635(...)
> INTEGER KSCALE
> REAL SCALE
> <..some code calculating KSCALE..>
> SCALE = 2.0**KSCALE
> PRINT *,'SCALE ',SCALE,KSCALE
>
> In the working case, I get
> SCALE 1.000000 0
> in the non-working case, I have
> SCALE 0.000000 0
>
> If I add further prints, I suddenly get no output at all.
> It looks a bit like there is memory corruption, but I ran with efence
> and tried valgrind, I didn't find anything.
>
> I'm a bit in a loss. How to debug such a mess?
> I also tried to run ftnchek, but it has quite some problems
> with this fortran95 code.
>
Can you post the entire subroutine that shows the problem?
You may have already mentioned the version, but could you
also include 'gfortran -v' output?
--
Steve