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 fortran/48404] SELECTED_REAL_KIND is returning KIND=16 when not available


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

Tobias Burnus <burnus at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |burnus at gcc dot gnu.org

--- Comment #3 from Tobias Burnus <burnus at gcc dot gnu.org> 2011-04-01 21:21:10 UTC ---
The following line calls libgfortran:
     j = SELECTED_REAL_KIND(i)

While the line
     REAL(KIND=16) :: x
is processed by the compiler itself.

The library obtains the available kinds at library compile time by asking the
compiler for the available kinds.

Thus, seemingly the compiler which compiled libgfortran supported REAL(16)
while the compiler currently installed on your system does not.

Thus: How have you obtained the compiler? Are you sure that the correct
compiler/library combination is used?

It seems as if you mix libgfortran of GCC 4.6 with a gfortran of GCC 4.x < 4.6. 


In principle, the libgfortran library is downward compatible, however, the
current versioning system does not quite anticipate that different GCC versions
might support different REAL kinds - I also do not see how one could easily fix
this - using, e.g., --disable-libquadmath-support, you could now build a 4.7
which does not support REAL(16) but which is otherwise fully compatible with a
4.6 which supports REAL(16) - unless one then uses REAL(16) functions.


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