This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug libfortran/25370] New: Bad value for sqrt of double complex


This code exhibit a weird dependance on whether it is statically linked or
dynamically linked:

$ cat foo.f90 
complex c
double complex d

c = (-1., 0.)
print *, c, sqrt(c)
d = c
print *, d, sqrt(d)
end

$ ./bin/gfortran -static foo.f90 && ./a.out
 ( -1.000000    ,  0.000000    ) (  0.000000    ,  1.000000    )
 ( -1.00000000000000     ,  0.00000000000000     ) (  0.00000000000000     , 
1.00000000000000     )
$ ./bin/gfortran foo.f90 && ./a.out
 ( -1.000000    ,  0.000000    ) (  0.000000    ,  1.000000    )
 ( -1.00000000000000     ,  0.00000000000000     ) ( 1.397677071793657E-312,
3.756040694101013E-317)


-- 
           Summary: Bad value for sqrt of double complex
           Product: gcc
           Version: 4.2.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: libfortran
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: fxcoudert at gcc dot gnu dot org
 GCC build triplet: i386-pc-solaris2.9
  GCC host triplet: i386-pc-solaris2.9
GCC target triplet: i386-pc-solaris2.9


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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]