https://gcc.gnu.org/bugzilla/show_bug.cgi?id=89034
Tom de Vries <vries at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |openacc CC| |tschwinge at gcc dot gnu.org Severity|normal |enhancement --- Comment #1 from Tom de Vries <vries at gcc dot gnu.org> --- This is a rewrite of abort-1.c that gets rid of the dg-shouldfail, by using on_exit: ... /* { dg-do run { target { ! openacc_host_selected } } } */ #include <stdio.h> #include <stdlib.h> #include <unistd.h> static int trace; static void exit_handler (int status, void *arg) { if (trace != 1) abort (); if (status != EXIT_FAILURE) abort (); _exit (0); } int main (void) { trace = 0; on_exit (exit_handler, NULL); trace++; #pragma acc parallel { abort (); } trace++; return 0; } /* { dg-output "libgomp: " } */ ...