This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [gomp] Expand empty parallel directives into empty statements
- From: Jakub Jelinek <jakub at redhat dot com>
- To: Diego Novillo <dnovillo at redhat dot com>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Tue, 1 Nov 2005 13:54:49 -0500
- Subject: Re: [gomp] Expand empty parallel directives into empty statements
- References: <200511011305.25598.dnovillo@redhat.com>
- Reply-to: Jakub Jelinek <jakub at redhat dot com>
On Tue, Nov 01, 2005 at 01:05:25PM -0500, Diego Novillo wrote:
>
> Avoids going through the hassle of creating new functions and emitting
> calls to the runtime library when the body of the parallel directive is
> empty at the time of expansion.
>
> Right now this only happens on silly input. In the future, it may happen
> because of earlier optimization.
>
>
> * tree.c (empty_body_p): New.
> * tree.h (empty_body_p): Declare.
> * omp-low.c (scan_omp_parallel): Replace empty parallel
> directives with an empty statement.
Is that a safe thing to do in presence of constructors and/or destructors
in vars mentioned explicitly in the clauses?
Jakub