gcc/libgomp/testsuite/libgomp.c/pr64824.c
Jakub Jelinek 4886ec8e70 re PR middle-end/64824 (ICE in gimple verification)
PR c/64824
	PR c/64868
gcc/c/
	* c-parser.c (c_parser_omp_atomic): Handle RDIV_EXPR.
gcc/cp/
	* parser.c (cp_parser_omp_atomic): Handle RDIV_EXPR.
gcc/c-family/
	* c-omp.c (c_finish_omp_atomic): Use TRUNC_DIV_EXPR
	instead of RDIV_EXPR.  Use build_binary_op instead of
	build2_loc.
libgomp/
	* testsuite/libgomp.c/pr64824.c: New test.
	* testsuite/libgomp.c/pr64868.c: New test.
	* testsuite/libgomp.c++/pr64824.C: New test.
	* testsuite/libgomp.c++/pr64868.C: New test.

From-SVN: r220420
2015-02-04 23:32:36 +01:00

17 lines
248 B
C

/* PR c/64824 */
/* { dg-do run } */
/* { dg-options "-O2 -fopenmp" } */
int
main ()
{
long long a;
long long b = 1LL;
int c = 3;
#pragma omp atomic capture
a = b = c << b;
if (b != 6LL || a != 6LL)
__builtin_abort ();
return 0;
}