public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/111938] New: Missing OpenACC/Fortran handling in 'gcc/fortran/frontend-passes.c'
@ 2023-10-23 16:16 tschwinge at gcc dot gnu.org
  2023-10-23 16:21 ` [Bug fortran/111938] " tschwinge at gcc dot gnu.org
  2024-01-07 11:29 ` tkoenig at gcc dot gnu.org
  0 siblings, 2 replies; 3+ messages in thread
From: tschwinge at gcc dot gnu.org @ 2023-10-23 16:16 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111938

            Bug ID: 111938
           Summary: Missing OpenACC/Fortran handling in
                    'gcc/fortran/frontend-passes.c'
           Product: gcc
           Version: 14.0
            Status: UNCONFIRMED
          Keywords: openacc
          Severity: normal
          Priority: P3
         Component: fortran
          Assignee: unassigned at gcc dot gnu.org
          Reporter: tschwinge at gcc dot gnu.org
                CC: burnus at gcc dot gnu.org, jakub at gcc dot gnu.org
  Target Milestone: ---

I've noticed that none of the OpenACC 'EXEC_OACC_[...]' codes (other than
'EXEC_OACC_ATOMIC') are handled in 'gcc/fortran/frontend-passes.c'
('gfc_code_walker'), and similarly the respective 'gfc_omp_clauses' members not
'WALK_SUBEXPR'ed.

At least a lot of (possibly, all?) OpenMP 'EXEC_OMP_[...]' codes and
'gfc_omp_clauses' members appear to be handled.  (Not verified in detail.)

Disabling the OpenMP handling, and running 'gomp.exp', I don't get much, but
still one ICE in 'gfortran.dg/gomp/pr92977.f90', and a dump scanning FAIL in
'gfortran.dg/gomp/workshare2.f90' (nothing for 'check-target-libgomp'), so I
conclude this code is doing something useful for OpenMP, and we should
investigate whether OpenACC also needs to be handled?

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

* [Bug fortran/111938] Missing OpenACC/Fortran handling in 'gcc/fortran/frontend-passes.c'
  2023-10-23 16:16 [Bug fortran/111938] New: Missing OpenACC/Fortran handling in 'gcc/fortran/frontend-passes.c' tschwinge at gcc dot gnu.org
@ 2023-10-23 16:21 ` tschwinge at gcc dot gnu.org
  2024-01-07 11:29 ` tkoenig at gcc dot gnu.org
  1 sibling, 0 replies; 3+ messages in thread
From: tschwinge at gcc dot gnu.org @ 2023-10-23 16:21 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111938

--- Comment #1 from Thomas Schwinge <tschwinge at gcc dot gnu.org> ---
(In reply to Thomas Schwinge from comment #0)
> 'EXEC_OACC_ATOMIC') are handled in 'gcc/fortran/frontend-passes.c'

> Disabling the OpenMP handling, and running 'gomp.exp', I don't get much, but
> still one ICE in 'gfortran.dg/gomp/pr92977.f90'

Aha: PR92977, PR93462.

> [...], so I
> conclude this code is doing something useful for OpenMP, and we should
> investigate whether OpenACC also needs to be handled?

That I already had suspected almost a decade ago;
<https://inbox.sourceware.org/87y4reb4fu.fsf@kepler.schwinge.homeip.net>
"OpenACC fortran front end":

| Doesn't gcc/fortran/frontend-passes:gfc_code_walker need to be updated
| for OpenACC?

;'-)

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

* [Bug fortran/111938] Missing OpenACC/Fortran handling in 'gcc/fortran/frontend-passes.c'
  2023-10-23 16:16 [Bug fortran/111938] New: Missing OpenACC/Fortran handling in 'gcc/fortran/frontend-passes.c' tschwinge at gcc dot gnu.org
  2023-10-23 16:21 ` [Bug fortran/111938] " tschwinge at gcc dot gnu.org
@ 2024-01-07 11:29 ` tkoenig at gcc dot gnu.org
  1 sibling, 0 replies; 3+ messages in thread
From: tkoenig at gcc dot gnu.org @ 2024-01-07 11:29 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111938

Thomas Koenig <tkoenig at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |missed-optimization
           Severity|normal                      |enhancement
     Ever confirmed|0                           |1
                 CC|                            |tkoenig at gcc dot gnu.org
   Last reconfirmed|                            |2024-01-07
             Status|UNCONFIRMED                 |NEW

--- Comment #2 from Thomas Koenig <tkoenig at gcc dot gnu.org> ---
I know next to nothing about OpenACC, so I cannot really do this
(but I know frontend-passes.cc).

Could you maybe provide a patch, or a list of what should go where?

Confirmed.

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

end of thread, other threads:[~2024-01-07 11:29 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-10-23 16:16 [Bug fortran/111938] New: Missing OpenACC/Fortran handling in 'gcc/fortran/frontend-passes.c' tschwinge at gcc dot gnu.org
2023-10-23 16:21 ` [Bug fortran/111938] " tschwinge at gcc dot gnu.org
2024-01-07 11:29 ` tkoenig 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).