public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/45030]  New: -fwhole-file: Bogus error message with ENTRY and different result types
@ 2010-07-22 13:23 burnus at gcc dot gnu dot org
  2010-07-22 13:42 ` [Bug fortran/45030] " burnus at gcc dot gnu dot org
                   ` (3 more replies)
  0 siblings, 4 replies; 7+ messages in thread
From: burnus at gcc dot gnu dot org @ 2010-07-22 13:23 UTC (permalink / raw)
  To: gcc-bugs

This is a bug which needs to be fixed before -fwhole-file can be enabled by
default. Otherwise, the test results look fine. (Note: I tested with
-fwhole-file enabled by default and including the patch for PR 44945.)


Extended test case: gfortran.fortran-torture/execute/entry_4.f90


real,    external :: g
                      1
Error: Return type mismatch of function 'g' at (1) (REAL(4)/INTEGER(4))


Test case:

function f()
  integer :: f
  real :: g
entry g()
end function

integer, external :: f
real,    external :: g
integer :: ff
real :: gg
ff = f()
gg = g()
end


-- 
           Summary: -fwhole-file: Bogus error message with ENTRY and
                    different result types
           Product: gcc
           Version: 4.6.0
            Status: UNCONFIRMED
          Keywords: rejects-valid
          Severity: normal
          Priority: P3
         Component: fortran
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: burnus at gcc dot gnu dot org


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


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Bug fortran/45030] -fwhole-file: Bogus error message with ENTRY and different result types
  2010-07-22 13:23 [Bug fortran/45030] New: -fwhole-file: Bogus error message with ENTRY and different result types burnus at gcc dot gnu dot org
@ 2010-07-22 13:42 ` burnus at gcc dot gnu dot org
  2010-07-23 11:25 ` burnus at gcc dot gnu dot org
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 7+ messages in thread
From: burnus at gcc dot gnu dot org @ 2010-07-22 13:42 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #1 from burnus at gcc dot gnu dot org  2010-07-22 13:42 -------
Another test case is: libgomp.fortran/retval1.f90
(Found via "cd $BUILD/*/libgomp; make check")


-- 


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


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Bug fortran/45030] -fwhole-file: Bogus error message with ENTRY and different result types
  2010-07-22 13:23 [Bug fortran/45030] New: -fwhole-file: Bogus error message with ENTRY and different result types burnus at gcc dot gnu dot org
  2010-07-22 13:42 ` [Bug fortran/45030] " burnus at gcc dot gnu dot org
@ 2010-07-23 11:25 ` burnus at gcc dot gnu dot org
  2010-07-23 20:08 ` burnus at gcc dot gnu dot org
  2010-07-23 20:09 ` burnus at gcc dot gnu dot org
  3 siblings, 0 replies; 7+ messages in thread
From: burnus at gcc dot gnu dot org @ 2010-07-23 11:25 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #2 from burnus at gcc dot gnu dot org  2010-07-23 11:24 -------
Created an attachment (id=21293)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=21293&action=view)
Draft patch

Draft patch. I was wondering whether one needs to take care of

(a) use names in case of use association - or can one not reach that function
in this case?

(b) C binding names, i.e.

subroutine foo() bind(C, name=bar)
...
entry foo2() bind(C, name=bar2)
...
end

interface
  subroutine Hello() bind(C,name=bar2)
  end
end interface

call Hello() ! << this should use the same backend decl as "ENTRY foo2".

(c) Whether this just fixes the error checking or whether the backend_decl is
also correct.

What do you think, Paul?


-- 


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


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Bug fortran/45030] -fwhole-file: Bogus error message with ENTRY and different result types
  2010-07-22 13:23 [Bug fortran/45030] New: -fwhole-file: Bogus error message with ENTRY and different result types burnus at gcc dot gnu dot org
  2010-07-22 13:42 ` [Bug fortran/45030] " burnus at gcc dot gnu dot org
  2010-07-23 11:25 ` burnus at gcc dot gnu dot org
@ 2010-07-23 20:08 ` burnus at gcc dot gnu dot org
  2010-07-23 20:09 ` burnus at gcc dot gnu dot org
  3 siblings, 0 replies; 7+ messages in thread
From: burnus at gcc dot gnu dot org @ 2010-07-23 20:08 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #3 from burnus at gcc dot gnu dot org  2010-07-23 20:07 -------
Subject: Bug 45030

Author: burnus
Date: Fri Jul 23 20:07:30 2010
New Revision: 162486

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=162486
Log:
2010-07-23  Tobias Burnus  <burnus@net-b.de>

        PR fortran/45030
        * resolve.c (resolve_global_procedure): Properly handle ENTRY.


Modified:
    trunk/gcc/fortran/ChangeLog
    trunk/gcc/fortran/resolve.c


-- 


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


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Bug fortran/45030] -fwhole-file: Bogus error message with ENTRY and different result types
  2010-07-22 13:23 [Bug fortran/45030] New: -fwhole-file: Bogus error message with ENTRY and different result types burnus at gcc dot gnu dot org
                   ` (2 preceding siblings ...)
  2010-07-23 20:08 ` burnus at gcc dot gnu dot org
@ 2010-07-23 20:09 ` burnus at gcc dot gnu dot org
  3 siblings, 0 replies; 7+ messages in thread
From: burnus at gcc dot gnu dot org @ 2010-07-23 20:09 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #4 from burnus at gcc dot gnu dot org  2010-07-23 20:08 -------
The ENTRY diagnostics issue of comment 0 is now fixed. I leave the PR open
until one has checked the issues raised in comment 1.


-- 


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


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Bug fortran/45030] -fwhole-file: Bogus error message with ENTRY and different result types
       [not found] <bug-45030-4@http.gcc.gnu.org/bugzilla/>
  2011-12-15 21:56 ` dominiq at lps dot ens.fr
@ 2011-12-16  7:46 ` burnus at gcc dot gnu.org
  1 sibling, 0 replies; 7+ messages in thread
From: burnus at gcc dot gnu.org @ 2011-12-16  7:46 UTC (permalink / raw)
  To: gcc-bugs

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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|WAITING                     |RESOLVED
         Resolution|                            |FIXED

--- Comment #6 from Tobias Burnus <burnus at gcc dot gnu.org> 2011-12-16 07:12:15 UTC ---
Let's mark it as fixed. There are probably still some issues, but it seems as
if comment 1 is (mostly) fine.


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Bug fortran/45030] -fwhole-file: Bogus error message with ENTRY and different result types
       [not found] <bug-45030-4@http.gcc.gnu.org/bugzilla/>
@ 2011-12-15 21:56 ` dominiq at lps dot ens.fr
  2011-12-16  7:46 ` burnus at gcc dot gnu.org
  1 sibling, 0 replies; 7+ messages in thread
From: dominiq at lps dot ens.fr @ 2011-12-15 21:56 UTC (permalink / raw)
  To: gcc-bugs

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

Dominique d'Humieres <dominiq at lps dot ens.fr> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |WAITING
   Last reconfirmed|                            |2011-12-15
     Ever Confirmed|0                           |1

--- Comment #5 from Dominique d'Humieres <dominiq at lps dot ens.fr> 2011-12-15 21:37:01 UTC ---
AFAICT the issues raised in comment #1 is fixed at least on 4.6.2 and trunk.
Tobias could you please confirm it?


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2011-12-16  7:12 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-07-22 13:23 [Bug fortran/45030] New: -fwhole-file: Bogus error message with ENTRY and different result types burnus at gcc dot gnu dot org
2010-07-22 13:42 ` [Bug fortran/45030] " burnus at gcc dot gnu dot org
2010-07-23 11:25 ` burnus at gcc dot gnu dot org
2010-07-23 20:08 ` burnus at gcc dot gnu dot org
2010-07-23 20:09 ` burnus at gcc dot gnu dot org
     [not found] <bug-45030-4@http.gcc.gnu.org/bugzilla/>
2011-12-15 21:56 ` dominiq at lps dot ens.fr
2011-12-16  7:46 ` burnus at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).