This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Move effective target check after other directives in c-c++-common/cpp/openmp-define-3.c


Hi!

On Mon, 14 Oct 2013 11:26:21 +0100, Kyrill Tkachov <kyrylo.tkachov@arm.com> wrote:
> This minuscule patch moves the dg-require-effective-target fopenmp line after 
> the other directives in the c-c++-common/cpp/openmp-define-3.c test. Otherwise 
> dejagnu still proceeds to add -fopenmp to the options which fails on bare metal 
> arm and aarch64 targets.

Thanks for reporting and fixing this -- I had not been aware of the
ordering requirements of dg-* directives.  From gcc/doc/sourcebuild.texi:

    @item @{ dg-require-effective-target @var{keyword} [@{ @var{selector} @}] @}
    Skip the test if [...]
    This directive must appear after any @code{dg-do} directive in the test
    and before any @code{dg-additional-sources} directive.
    [...]

> --- a/gcc/testsuite/c-c++-common/cpp/openmp-define-3.c
> +++ b/gcc/testsuite/c-c++-common/cpp/openmp-define-3.c
> @@ -1,6 +1,6 @@
> -/* { dg-require-effective-target fopenmp } */
>  /* { dg-options "-fopenmp" } */
>  /* { dg-do preprocess } */
> +/* { dg-require-effective-target fopenmp } */

The other testsuite files that I added in r203417 should also be adapted
accordingly.  Do you want to do that, or want me to do it?


GrÃÃe,
 Thomas

Attachment: pgpczVWtW3V6E.pgp
Description: PGP signature


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]