public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug debug/104517] New: '-fcompare-debug' failure w/ -O1 -fopenmp -fno-tree-ter
@ 2022-02-13  6:48 asolokha at gmx dot com
  2022-02-13  6:49 ` [Bug debug/104517] " asolokha at gmx dot com
                   ` (9 more replies)
  0 siblings, 10 replies; 11+ messages in thread
From: asolokha at gmx dot com @ 2022-02-13  6:48 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 104517
           Summary: '-fcompare-debug' failure w/ -O1 -fopenmp
                    -fno-tree-ter
           Product: gcc
           Version: 12.0
            Status: UNCONFIRMED
          Keywords: compare-debug-failure, openmp
          Severity: normal
          Priority: P3
         Component: debug
          Assignee: unassigned at gcc dot gnu.org
          Reporter: asolokha at gmx dot com
  Target Milestone: ---

Created attachment 52429
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=52429&action=edit
Testcase

gcc 12.0.1 20220206 snapshot (g:8eb329e963593342855b6072e5692659107337b7) fails
-fcompare-debug check when compiling the attached testcase, reduced from
gcc/testsuite/c-c++-common/gomp/clauses-1.c, w/ -O1 -fopenmp -fno-tree-ter:

% gcc-12.0.1 -O1 -fcompare-debug -fopenmp -fno-tree-ter -c isdtsldh.c
-save-temps
gcc-12.0.1: error: isdtsldh.c: '-fcompare-debug' failure

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

* [Bug debug/104517] '-fcompare-debug' failure w/ -O1 -fopenmp -fno-tree-ter
  2022-02-13  6:48 [Bug debug/104517] New: '-fcompare-debug' failure w/ -O1 -fopenmp -fno-tree-ter asolokha at gmx dot com
@ 2022-02-13  6:49 ` asolokha at gmx dot com
  2022-02-13 23:11 ` pinskia at gcc dot gnu.org
                   ` (8 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: asolokha at gmx dot com @ 2022-02-13  6:49 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #1 from Arseny Solokha <asolokha at gmx dot com> ---
Created attachment 52430
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=52430&action=edit
gkd diff

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

* [Bug debug/104517] '-fcompare-debug' failure w/ -O1 -fopenmp -fno-tree-ter
  2022-02-13  6:48 [Bug debug/104517] New: '-fcompare-debug' failure w/ -O1 -fopenmp -fno-tree-ter asolokha at gmx dot com
  2022-02-13  6:49 ` [Bug debug/104517] " asolokha at gmx dot com
@ 2022-02-13 23:11 ` pinskia at gcc dot gnu.org
  2022-02-13 23:43 ` asolokha at gmx dot com
                   ` (7 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: pinskia at gcc dot gnu.org @ 2022-02-13 23:11 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
I can't reproduce it on the trunk.

I wonder if it was fixed by the patch which fixed PR 104459.

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

* [Bug debug/104517] '-fcompare-debug' failure w/ -O1 -fopenmp -fno-tree-ter
  2022-02-13  6:48 [Bug debug/104517] New: '-fcompare-debug' failure w/ -O1 -fopenmp -fno-tree-ter asolokha at gmx dot com
  2022-02-13  6:49 ` [Bug debug/104517] " asolokha at gmx dot com
  2022-02-13 23:11 ` pinskia at gcc dot gnu.org
@ 2022-02-13 23:43 ` asolokha at gmx dot com
  2022-02-13 23:53 ` pinskia at gcc dot gnu.org
                   ` (6 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: asolokha at gmx dot com @ 2022-02-13 23:43 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #3 from Arseny Solokha <asolokha at gmx dot com> ---
No, it still fails w/ 20220213 snapshot
(g:58aeb75d4097010ad9bb72b964265b18ab284f93). You should try adding -save-temps
to the command line.

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

* [Bug debug/104517] '-fcompare-debug' failure w/ -O1 -fopenmp -fno-tree-ter
  2022-02-13  6:48 [Bug debug/104517] New: '-fcompare-debug' failure w/ -O1 -fopenmp -fno-tree-ter asolokha at gmx dot com
                   ` (2 preceding siblings ...)
  2022-02-13 23:43 ` asolokha at gmx dot com
@ 2022-02-13 23:53 ` pinskia at gcc dot gnu.org
  2022-02-14 13:01 ` jakub at gcc dot gnu.org
                   ` (5 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: pinskia at gcc dot gnu.org @ 2022-02-13 23:53 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #4 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
yes adding -save-temps causes the difference, interesting.

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

* [Bug debug/104517] '-fcompare-debug' failure w/ -O1 -fopenmp -fno-tree-ter
  2022-02-13  6:48 [Bug debug/104517] New: '-fcompare-debug' failure w/ -O1 -fopenmp -fno-tree-ter asolokha at gmx dot com
                   ` (3 preceding siblings ...)
  2022-02-13 23:53 ` pinskia at gcc dot gnu.org
@ 2022-02-14 13:01 ` jakub at gcc dot gnu.org
  2022-02-15  9:25 ` cvs-commit at gcc dot gnu.org
                   ` (4 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: jakub at gcc dot gnu.org @ 2022-02-14 13:01 UTC (permalink / raw)
  To: gcc-bugs

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

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Last reconfirmed|                            |2022-02-14
           Assignee|unassigned at gcc dot gnu.org      |jakub at gcc dot gnu.org
             Status|UNCONFIRMED                 |ASSIGNED
     Ever confirmed|0                           |1

--- Comment #5 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Created attachment 52436
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=52436&action=edit
gcc12-pr104517.patch

Untested fix.

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

* [Bug debug/104517] '-fcompare-debug' failure w/ -O1 -fopenmp -fno-tree-ter
  2022-02-13  6:48 [Bug debug/104517] New: '-fcompare-debug' failure w/ -O1 -fopenmp -fno-tree-ter asolokha at gmx dot com
                   ` (4 preceding siblings ...)
  2022-02-14 13:01 ` jakub at gcc dot gnu.org
@ 2022-02-15  9:25 ` cvs-commit at gcc dot gnu.org
  2022-02-19  8:03 ` cvs-commit at gcc dot gnu.org
                   ` (3 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-02-15  9:25 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #6 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Jakub Jelinek <jakub@gcc.gnu.org>:

https://gcc.gnu.org/g:6a0d6e7ca9b9e338e82572db79c26168684a7441

commit r12-7237-g6a0d6e7ca9b9e338e82572db79c26168684a7441
Author: Jakub Jelinek <jakub@redhat.com>
Date:   Tue Feb 15 10:22:30 2022 +0100

    openmp: Make finalize_task_copyfn order reproduceable [PR104517]

    The following testcase fails -fcompare-debug, because finalize_task_copyfn
    was invoked from splay tree destruction, whose order can in some cases
    depend on -g/-g0.  The fix is to queue the task stmts that need copyfn
    in a vector and run finalize_task_copyfn on elements of that vector.

    2022-02-15  Jakub Jelinek  <jakub@redhat.com>

            PR debug/104517
            * omp-low.cc (task_cpyfns): New variable.
            (delete_omp_context): Don't call finalize_task_copyfn from here.
            (create_task_copyfn): Push task_stmt into task_cpyfns.
            (execute_lower_omp): Call finalize_task_copyfn here on entries from
            task_cpyfns vector and release the vector.

            * gcc.dg/gomp/pr104517.c: New test.

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

* [Bug debug/104517] '-fcompare-debug' failure w/ -O1 -fopenmp -fno-tree-ter
  2022-02-13  6:48 [Bug debug/104517] New: '-fcompare-debug' failure w/ -O1 -fopenmp -fno-tree-ter asolokha at gmx dot com
                   ` (5 preceding siblings ...)
  2022-02-15  9:25 ` cvs-commit at gcc dot gnu.org
@ 2022-02-19  8:03 ` cvs-commit at gcc dot gnu.org
  2022-05-10  8:24 ` cvs-commit at gcc dot gnu.org
                   ` (2 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-02-19  8:03 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #7 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-11 branch has been updated by Jakub Jelinek
<jakub@gcc.gnu.org>:

https://gcc.gnu.org/g:14f0b450f7976f824428f0d35b4e7e6dc162f708

commit r11-9606-g14f0b450f7976f824428f0d35b4e7e6dc162f708
Author: Jakub Jelinek <jakub@redhat.com>
Date:   Tue Feb 15 10:22:30 2022 +0100

    openmp: Make finalize_task_copyfn order reproduceable [PR104517]

    The following testcase fails -fcompare-debug, because finalize_task_copyfn
    was invoked from splay tree destruction, whose order can in some cases
    depend on -g/-g0.  The fix is to queue the task stmts that need copyfn
    in a vector and run finalize_task_copyfn on elements of that vector.

    2022-02-15  Jakub Jelinek  <jakub@redhat.com>

            PR debug/104517
            * omp-low.c (task_cpyfns): New variable.
            (delete_omp_context): Don't call finalize_task_copyfn from here.
            (create_task_copyfn): Push task_stmt into task_cpyfns.
            (execute_lower_omp): Call finalize_task_copyfn here on entries from
            task_cpyfns vector and release the vector.

            * gcc.dg/gomp/pr104517.c: New test.

    (cherry picked from commit 6a0d6e7ca9b9e338e82572db79c26168684a7441)

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

* [Bug debug/104517] '-fcompare-debug' failure w/ -O1 -fopenmp -fno-tree-ter
  2022-02-13  6:48 [Bug debug/104517] New: '-fcompare-debug' failure w/ -O1 -fopenmp -fno-tree-ter asolokha at gmx dot com
                   ` (6 preceding siblings ...)
  2022-02-19  8:03 ` cvs-commit at gcc dot gnu.org
@ 2022-05-10  8:24 ` cvs-commit at gcc dot gnu.org
  2022-05-11  6:24 ` cvs-commit at gcc dot gnu.org
  2022-05-11  6:36 ` jakub at gcc dot gnu.org
  9 siblings, 0 replies; 11+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-05-10  8:24 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #8 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-10 branch has been updated by Jakub Jelinek
<jakub@gcc.gnu.org>:

https://gcc.gnu.org/g:d028f4313ae55837b30bec6b737c92a229b4f23d

commit r10-10681-gd028f4313ae55837b30bec6b737c92a229b4f23d
Author: Jakub Jelinek <jakub@redhat.com>
Date:   Tue Feb 15 10:22:30 2022 +0100

    openmp: Make finalize_task_copyfn order reproduceable [PR104517]

    The following testcase fails -fcompare-debug, because finalize_task_copyfn
    was invoked from splay tree destruction, whose order can in some cases
    depend on -g/-g0.  The fix is to queue the task stmts that need copyfn
    in a vector and run finalize_task_copyfn on elements of that vector.

    2022-02-15  Jakub Jelinek  <jakub@redhat.com>

            PR debug/104517
            * omp-low.c (task_cpyfns): New variable.
            (delete_omp_context): Don't call finalize_task_copyfn from here.
            (create_task_copyfn): Push task_stmt into task_cpyfns.
            (execute_lower_omp): Call finalize_task_copyfn here on entries from
            task_cpyfns vector and release the vector.

    (cherry picked from commit 6a0d6e7ca9b9e338e82572db79c26168684a7441)

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

* [Bug debug/104517] '-fcompare-debug' failure w/ -O1 -fopenmp -fno-tree-ter
  2022-02-13  6:48 [Bug debug/104517] New: '-fcompare-debug' failure w/ -O1 -fopenmp -fno-tree-ter asolokha at gmx dot com
                   ` (7 preceding siblings ...)
  2022-05-10  8:24 ` cvs-commit at gcc dot gnu.org
@ 2022-05-11  6:24 ` cvs-commit at gcc dot gnu.org
  2022-05-11  6:36 ` jakub at gcc dot gnu.org
  9 siblings, 0 replies; 11+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-05-11  6:24 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #9 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-9 branch has been updated by Jakub Jelinek
<jakub@gcc.gnu.org>:

https://gcc.gnu.org/g:57e0795a44639d1cc84abbdd46c507cc64dfa2f8

commit r9-10129-g57e0795a44639d1cc84abbdd46c507cc64dfa2f8
Author: Jakub Jelinek <jakub@redhat.com>
Date:   Tue Feb 15 10:22:30 2022 +0100

    openmp: Make finalize_task_copyfn order reproduceable [PR104517]

    The following testcase fails -fcompare-debug, because finalize_task_copyfn
    was invoked from splay tree destruction, whose order can in some cases
    depend on -g/-g0.  The fix is to queue the task stmts that need copyfn
    in a vector and run finalize_task_copyfn on elements of that vector.

    2022-02-15  Jakub Jelinek  <jakub@redhat.com>

            PR debug/104517
            * omp-low.c (task_cpyfns): New variable.
            (delete_omp_context): Don't call finalize_task_copyfn from here.
            (create_task_copyfn): Push task_stmt into task_cpyfns.
            (execute_lower_omp): Call finalize_task_copyfn here on entries from
            task_cpyfns vector and release the vector.

    (cherry picked from commit 6a0d6e7ca9b9e338e82572db79c26168684a7441)

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

* [Bug debug/104517] '-fcompare-debug' failure w/ -O1 -fopenmp -fno-tree-ter
  2022-02-13  6:48 [Bug debug/104517] New: '-fcompare-debug' failure w/ -O1 -fopenmp -fno-tree-ter asolokha at gmx dot com
                   ` (8 preceding siblings ...)
  2022-05-11  6:24 ` cvs-commit at gcc dot gnu.org
@ 2022-05-11  6:36 ` jakub at gcc dot gnu.org
  9 siblings, 0 replies; 11+ messages in thread
From: jakub at gcc dot gnu.org @ 2022-05-11  6:36 UTC (permalink / raw)
  To: gcc-bugs

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

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

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

--- Comment #10 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Fixed.

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

end of thread, other threads:[~2022-05-11  6:36 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-02-13  6:48 [Bug debug/104517] New: '-fcompare-debug' failure w/ -O1 -fopenmp -fno-tree-ter asolokha at gmx dot com
2022-02-13  6:49 ` [Bug debug/104517] " asolokha at gmx dot com
2022-02-13 23:11 ` pinskia at gcc dot gnu.org
2022-02-13 23:43 ` asolokha at gmx dot com
2022-02-13 23:53 ` pinskia at gcc dot gnu.org
2022-02-14 13:01 ` jakub at gcc dot gnu.org
2022-02-15  9:25 ` cvs-commit at gcc dot gnu.org
2022-02-19  8:03 ` cvs-commit at gcc dot gnu.org
2022-05-10  8:24 ` cvs-commit at gcc dot gnu.org
2022-05-11  6:24 ` cvs-commit at gcc dot gnu.org
2022-05-11  6:36 ` jakub 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).