Commit 45780041 by Tom de Vries Committed by Tom de Vries

Add goacc/uninit-dim-clause.{c,f95}

2016-03-24  Tom de Vries  <tom@codesourcery.com>

	* c-c++-common/goacc/uninit-dim-clause.c: New test.
	* gfortran.dg/goacc/uninit-dim-clause.f95: New test.

From-SVN: r234458
parent 887ab4e5
2016-03-24 Tom de Vries <tom@codesourcery.com>
* c-c++-common/goacc/uninit-dim-clause.c: New test.
* gfortran.dg/goacc/uninit-dim-clause.f95: New test.
2016-03-24 Patrick Palka <ppalka@gcc.gnu.org>
PR c++/62212
......
/* { dg-do compile } */
/* { dg-additional-options "-Wuninitialized" } */
#include <stdbool.h>
int
main (void)
{
int i, j, k;
#pragma acc parallel num_gangs(i) /* { dg-warning "is used uninitialized in this function" } */
;
#pragma acc parallel num_workers(j) /* { dg-warning "is used uninitialized in this function" } */
;
#pragma acc parallel vector_length(k) /* { dg-warning "is used uninitialized in this function" } */
;
}
! { dg-do compile }
! { dg-additional-options "-Wuninitialized" }
program test
implicit none
integer :: i, j, k
!$acc parallel num_gangs(i) ! { dg-warning "is used uninitialized in this function" }
!$acc end parallel
!$acc parallel num_workers(j) ! { dg-warning "is used uninitialized in this function" }
!$acc end parallel
!$acc parallel vector_length(k) ! { dg-warning "is used uninitialized in this function" }
!$acc end parallel
end program test
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment