public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/52531] New: Compilation fails with polymorphic dummy argument and OpenMP
@ 2012-03-08 14:05 kaladhorn at me dot com
2012-03-08 15:12 ` [Bug fortran/52531] [OOP] " jakub at gcc dot gnu.org
` (7 more replies)
0 siblings, 8 replies; 9+ messages in thread
From: kaladhorn at me dot com @ 2012-03-08 14:05 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52531
Bug #: 52531
Summary: Compilation fails with polymorphic dummy argument and
OpenMP
Classification: Unclassified
Product: gcc
Version: 4.7.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: fortran
AssignedTo: unassigned@gcc.gnu.org
ReportedBy: kaladhorn@me.com
The following code does not compile:
--
module test_mod
type, public :: test_type
end type
contains
subroutine foo(bar)
type(test_type) :: bar
!$omp parallel default(none) shared(bar) ! Compiles if one removes
default(none)
call question(bar)
!$omp end parallel
end subroutine
subroutine question(var)
class(test_type), intent(in) :: var ! Compiles if one replaces class by
type
end subroutine
end module
--
The error message is:
‘__vtab_test_mod_Test_type’ not specified in enclosing parallel
This was reproduced with gfortran 4.6 (gcc version 4.6.3 (GCC) ) and 4.7 (gcc
version 4.7.0 20120121 (experimental) (GCC) ) on x86_64-unknown-linux-gnu .
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug fortran/52531] [OOP] Compilation fails with polymorphic dummy argument and OpenMP
2012-03-08 14:05 [Bug fortran/52531] New: Compilation fails with polymorphic dummy argument and OpenMP kaladhorn at me dot com
@ 2012-03-08 15:12 ` jakub at gcc dot gnu.org
2012-03-08 19:33 ` kaladhorn at me dot com
` (6 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: jakub at gcc dot gnu.org @ 2012-03-08 15:12 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52531
Jakub Jelinek <jakub at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |jakub at gcc dot gnu.org
--- Comment #1 from Jakub Jelinek <jakub at gcc dot gnu.org> 2012-03-08 15:11:03 UTC ---
OpenMP 3.1 or earlier releases don't cover Fortran 2003 nor 2008, so what you
are trying to compile is not valid.
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug fortran/52531] [OOP] Compilation fails with polymorphic dummy argument and OpenMP
2012-03-08 14:05 [Bug fortran/52531] New: Compilation fails with polymorphic dummy argument and OpenMP kaladhorn at me dot com
2012-03-08 15:12 ` [Bug fortran/52531] [OOP] " jakub at gcc dot gnu.org
@ 2012-03-08 19:33 ` kaladhorn at me dot com
2012-06-08 13:01 ` janus at gcc dot gnu.org
` (5 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: kaladhorn at me dot com @ 2012-03-08 19:33 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52531
--- Comment #2 from kaladhorn at me dot com 2012-03-08 19:33:24 UTC ---
(In reply to comment #1)
> OpenMP 3.1 or earlier releases don't cover Fortran 2003 nor 2008, so what you
> are trying to compile is not valid.
hmm that's true, I did not think of it that way. My apologies, then.
However, I think a proper error message would be nice.
Out of curiosity, would there be a technical issue in this case?
It sure seemed natural to me.
Thanks!
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug fortran/52531] [OOP] Compilation fails with polymorphic dummy argument and OpenMP
2012-03-08 14:05 [Bug fortran/52531] New: Compilation fails with polymorphic dummy argument and OpenMP kaladhorn at me dot com
2012-03-08 15:12 ` [Bug fortran/52531] [OOP] " jakub at gcc dot gnu.org
2012-03-08 19:33 ` kaladhorn at me dot com
@ 2012-06-08 13:01 ` janus at gcc dot gnu.org
2012-06-08 18:46 ` kaladhorn at me dot com
` (4 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: janus at gcc dot gnu.org @ 2012-06-08 13:01 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52531
janus at gcc dot gnu.org changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |janus at gcc dot gnu.org
--- Comment #3 from janus at gcc dot gnu.org 2012-06-08 13:00:53 UTC ---
(In reply to comment #2)
> Out of curiosity, would there be a technical issue in this case?
> It sure seemed natural to me.
AFAICS there should not be any huge issues. One might consider to implement
this as an extension.
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug fortran/52531] [OOP] Compilation fails with polymorphic dummy argument and OpenMP
2012-03-08 14:05 [Bug fortran/52531] New: Compilation fails with polymorphic dummy argument and OpenMP kaladhorn at me dot com
` (2 preceding siblings ...)
2012-06-08 13:01 ` janus at gcc dot gnu.org
@ 2012-06-08 18:46 ` kaladhorn at me dot com
2012-06-09 9:35 ` janus at gcc dot gnu.org
` (3 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: kaladhorn at me dot com @ 2012-06-08 18:46 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52531
--- Comment #4 from kaladhorn at me dot com 2012-06-08 18:46:11 UTC ---
(In reply to comment #3)
> (In reply to comment #2)
> > Out of curiosity, would there be a technical issue in this case?
> > It sure seemed natural to me.
>
> AFAICS there should not be any huge issues. One might consider to implement
> this as an extension.
If it does not hurt, I think it would be a good thing.
As far as I am concerned, I engineered around it, as it is really an edge case
we do not want to rely on.
It arguably makes some code uglier, though.
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug fortran/52531] [OOP] Compilation fails with polymorphic dummy argument and OpenMP
2012-03-08 14:05 [Bug fortran/52531] New: Compilation fails with polymorphic dummy argument and OpenMP kaladhorn at me dot com
` (3 preceding siblings ...)
2012-06-08 18:46 ` kaladhorn at me dot com
@ 2012-06-09 9:35 ` janus at gcc dot gnu.org
2013-03-17 17:07 ` janus at gcc dot gnu.org
` (2 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: janus at gcc dot gnu.org @ 2012-06-09 9:35 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52531
--- Comment #5 from janus at gcc dot gnu.org 2012-06-09 09:34:53 UTC ---
Note: Apart from the two workarounds mentioned in the test case, there is one
other possibility to make it work, namely to make 'bar' also polymorphic (like
the dummy 'var'), e.g.:
class(test_type), allocatable :: bar
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug fortran/52531] [OOP] Compilation fails with polymorphic dummy argument and OpenMP
2012-03-08 14:05 [Bug fortran/52531] New: Compilation fails with polymorphic dummy argument and OpenMP kaladhorn at me dot com
` (4 preceding siblings ...)
2012-06-09 9:35 ` janus at gcc dot gnu.org
@ 2013-03-17 17:07 ` janus at gcc dot gnu.org
2013-03-17 17:09 ` janus at gcc dot gnu.org
2013-07-24 7:29 ` janus at gcc dot gnu.org
7 siblings, 0 replies; 9+ messages in thread
From: janus at gcc dot gnu.org @ 2013-03-17 17:07 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52531
janus at gcc dot gnu.org changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |valeryweber at hotmail dot
| |com
--- Comment #6 from janus at gcc dot gnu.org 2013-03-17 17:06:41 UTC ---
*** Bug 55282 has been marked as a duplicate of this bug. ***
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug fortran/52531] [OOP] Compilation fails with polymorphic dummy argument and OpenMP
2012-03-08 14:05 [Bug fortran/52531] New: Compilation fails with polymorphic dummy argument and OpenMP kaladhorn at me dot com
` (5 preceding siblings ...)
2013-03-17 17:07 ` janus at gcc dot gnu.org
@ 2013-03-17 17:09 ` janus at gcc dot gnu.org
2013-07-24 7:29 ` janus at gcc dot gnu.org
7 siblings, 0 replies; 9+ messages in thread
From: janus at gcc dot gnu.org @ 2013-03-17 17:09 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52531
janus at gcc dot gnu.org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Last reconfirmed| |2013-03-17
Ever Confirmed|0 |1
Severity|normal |enhancement
--- Comment #7 from janus at gcc dot gnu.org 2013-03-17 17:09:12 UTC ---
Note that OpenMP 4.0 RC2 still lists polymorphic entities as unsupported, cf.
http://openmp.org/wp/openmp-specifications/
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Bug fortran/52531] [OOP] Compilation fails with polymorphic dummy argument and OpenMP
2012-03-08 14:05 [Bug fortran/52531] New: Compilation fails with polymorphic dummy argument and OpenMP kaladhorn at me dot com
` (6 preceding siblings ...)
2013-03-17 17:09 ` janus at gcc dot gnu.org
@ 2013-07-24 7:29 ` janus at gcc dot gnu.org
7 siblings, 0 replies; 9+ messages in thread
From: janus at gcc dot gnu.org @ 2013-07-24 7:29 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52531
--- Comment #8 from janus at gcc dot gnu.org ---
(In reply to janus from comment #7)
> Note that OpenMP 4.0 RC2 still lists polymorphic entities as unsupported,
> cf. http://openmp.org/wp/openmp-specifications/
Update: OpenMP has been officially released by now, but polymorphic variables
continue to be unsupported.
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2013-07-24 7:29 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-03-08 14:05 [Bug fortran/52531] New: Compilation fails with polymorphic dummy argument and OpenMP kaladhorn at me dot com
2012-03-08 15:12 ` [Bug fortran/52531] [OOP] " jakub at gcc dot gnu.org
2012-03-08 19:33 ` kaladhorn at me dot com
2012-06-08 13:01 ` janus at gcc dot gnu.org
2012-06-08 18:46 ` kaladhorn at me dot com
2012-06-09 9:35 ` janus at gcc dot gnu.org
2013-03-17 17:07 ` janus at gcc dot gnu.org
2013-03-17 17:09 ` janus at gcc dot gnu.org
2013-07-24 7:29 ` janus 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).