Skip to content

Commit aa14326

Browse files
committed
GCN, nvptx offloading: Restrain 'WARNING: program timed out.' while in 'dynamic_cast' only for effective-target 'offload_device' [PR119692]
In PR119692 "C++ 'typeinfo', 'vtable' vs. OpenACC, OpenMP 'target' offloading": > --- Comment #8 from Rainer Orth <ro at gcc dot gnu.org> --- > The last commit made things worse on sparc-sun-solaris2.11: since that one > (dg-timeout 10) I regularly get > > WARNING: libgomp.c++/target-exceptions-bad_cast-1.C (test for excess errors) > program timed out. > FAIL: libgomp.c++/target-exceptions-bad_cast-1.C (test for excess errors) > UNRESOLVED: libgomp.c++/target-exceptions-bad_cast-1.C compilation failed to produce executable > UNRESOLVED: libgomp.c++/target-exceptions-bad_cast-1.C scan-tree-dump-times optimized "gimple_call <__cxa_bad_cast, " 1 > > Before that, the test had no issue. Compiling the test on an unloaded system > usually takes less than 1 sec, but when fully loaded, times can go up. To keep things simple, let's restrict this temporary (yeah...) workaround to apply only for effective-target 'offload_device', just like the 'dg-xfail-run-if' itself. PR target/119692 libgomp/ * testsuite/libgomp.c++/pr119692-1-4.C: '{ dg-timeout 10 { target offload_device } }'. * testsuite/libgomp.c++/pr119692-1-5.C: Likewise. * testsuite/libgomp.c++/target-exceptions-bad_cast-1.C: Likewise. * testsuite/libgomp.c++/target-exceptions-bad_cast-2.C: Likewise. * testsuite/libgomp.oacc-c++/exceptions-bad_cast-1.C: Likewise. * testsuite/libgomp.oacc-c++/exceptions-bad_cast-2.C: Likewise.
1 parent a33f9d1 commit aa14326

File tree

6 files changed

+6
-6
lines changed

6 files changed

+6
-6
lines changed

libgomp/testsuite/libgomp.c++/pr119692-1-4.C

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
{ dg-xfail-run-if PR119692 { offload_device } } */
66
/* There are configurations where we 'WARNING: program timed out.' while in
77
'dynamic_cast', see <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=119692#c6>.
8-
{ dg-timeout 10 } ... to make sure that happens quickly. */
8+
{ dg-timeout 10 { target offload_device } } ... to make sure that happens quickly. */
99
/* { dg-additional-options -fdump-tree-gimple } */
1010

1111
#include "pr119692-1-1.C"

libgomp/testsuite/libgomp.c++/pr119692-1-5.C

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
{ dg-xfail-run-if PR119692 { offload_device } } */
66
/* There are configurations where we 'WARNING: program timed out.' while in
77
'dynamic_cast', see <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=119692#c6>.
8-
{ dg-timeout 10 } ... to make sure that happens quickly. */
8+
{ dg-timeout 10 { target offload_device } } ... to make sure that happens quickly. */
99
/* { dg-additional-options -fdump-tree-gimple } */
1010

1111
#include "pr119692-1-1.C"

libgomp/testsuite/libgomp.c++/target-exceptions-bad_cast-1.C

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,4 +25,4 @@
2525
{ dg-shouldfail {'std::bad_cast' exception} } */
2626
/* There are configurations where we 'WARNING: program timed out.' while in
2727
'dynamic_cast', see <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=119692#c6>.
28-
{ dg-timeout 10 } ... to make sure that happens quickly. */
28+
{ dg-timeout 10 { target offload_device } } ... to make sure that happens quickly. */

libgomp/testsuite/libgomp.c++/target-exceptions-bad_cast-2.C

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,4 +24,4 @@
2424
{ dg-shouldfail {'MyException' exception} { offload_device } } */
2525
/* There are configurations where we 'WARNING: program timed out.' while in
2626
'dynamic_cast', see <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=119692#c6>.
27-
{ dg-timeout 10 } ... to make sure that happens quickly. */
27+
{ dg-timeout 10 { target offload_device } } ... to make sure that happens quickly. */

libgomp/testsuite/libgomp.oacc-c++/exceptions-bad_cast-1.C

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,4 +54,4 @@ int main()
5454
{ dg-shouldfail {'std::bad_cast' exception} } */
5555
/* There are configurations where we 'WARNING: program timed out.' while in
5656
'dynamic_cast', see <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=119692#c6>.
57-
{ dg-timeout 10 } ... to make sure that happens quickly. */
57+
{ dg-timeout 10 { target offload_device } } ... to make sure that happens quickly. */

libgomp/testsuite/libgomp.oacc-c++/exceptions-bad_cast-2.C

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,4 +60,4 @@ int main()
6060
{ dg-shouldfail {'std::bad_cast' exception} { ! openacc_host_selected } } */
6161
/* There are configurations where we 'WARNING: program timed out.' while in
6262
'dynamic_cast', see <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=119692#c6>.
63-
{ dg-timeout 10 } ... to make sure that happens quickly. */
63+
{ dg-timeout 10 { target offload_device } } ... to make sure that happens quickly. */

0 commit comments

Comments
 (0)