gcc/testsuite:
* gcc.c-torture/execute/
20030913-1.c: Rename glob to g.
* gcc.c-torture/execute/960218-1.c: Rename glob to gl.
* gcc.c-torture/execute/complex-6.c: Rename err to e.
* gcc.dg/torture/ssa-pta-fn-1.c: Rename glob to g.
libgomp:
* testsuite/libgomp.c/pr39591-1.c: Rename err to e.
* testsuite/libgomp.c/pr39591-2.c: Likewise.
* testsuite/libgomp.c/pr39591-3.c: Likewise.
* testsuite/libgomp.c/private-1.c: Likewise.
* testsuite/libgomp.c/task-1.c: Likewise.
* testsuite/libgomp.c/task-5.c: Renamed err to serr.
From-SVN: r278571
+2019-11-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
+
+ * gcc.c-torture/execute/20030913-1.c: Rename glob to g.
+ * gcc.c-torture/execute/960218-1.c: Rename glob to gl.
+ * gcc.c-torture/execute/complex-6.c: Rename err to e.
+ * gcc.dg/torture/ssa-pta-fn-1.c: Rename glob to g.
+
2019-11-21 Marek Polacek <polacek@redhat.com>
PR c++/92450 - ICE with invalid nested name specifier.
/* Assignments via pointers pointing to global variables were being killed
by SSA-DCE. Test contributed by Paul Brook <paul@nowt.org> */
-int glob;
+int g;
void
fn2(int ** q)
{
- *q = &glob;
+ *q = &g;
}
void test()
int main()
{
test();
- if (glob != 42) abort();
+ if (g != 42) abort();
exit (0);
}
-int glob;
+int gl;
g (x)
{
- glob = x;
+ gl = x;
return 0;
}
main ()
{
f (3);
- if (glob != -4)
+ if (gl != -4)
abort ();
exit (0);
}
#include <stdlib.h>
#include <stdio.h>
-int err;
+int e;
#define TEST(TYPE, FUNC) \
__complex__ TYPE \
if (res != 1.0 - 2.0i) \
{ \
printf ("test_" #FUNC " failed\n"); \
- ++err; \
+ ++e; \
} \
}
main (void)
{
- err = 0;
+ e = 0;
test_float ();
test_double ();
test_int ();
test_long_int ();
- if (err != 0)
+ if (e != 0)
abort ();
return 0;
/* { dg-skip-if "" { *-*-* } { "-O0" "-fno-fat-lto-objects" } { "" } } */
extern void abort (void);
-int *glob;
+int *g;
int dummy;
int * __attribute__((noinline,const))
foo_pure(int *p) { return p + dummy; }
int * __attribute__((noinline))
-foo_normal(int *p) { glob = p; return p; }
+foo_normal(int *p) { g = p; return p; }
void test_const(void)
{
+2019-11-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
+
+ * testsuite/libgomp.c/pr39591-1.c: Rename err to e.
+ * testsuite/libgomp.c/pr39591-2.c: Likewise.
+ * testsuite/libgomp.c/pr39591-3.c: Likewise.
+ * testsuite/libgomp.c/private-1.c: Likewise.
+ * testsuite/libgomp.c/task-1.c: Likewise.
+ * testsuite/libgomp.c/task-5.c: Renamed err to serr.
+
2019-11-20 Julian Brown <julian@codesourcery.com>
* plugin/plugin-gcn.c (wait_for_queue_nonfull): Don't lock/unlock
extern void abort (void);
-int err;
+int e;
int
main (void)
for (j = 0; j < sizeof array / sizeof array[0]; j++)
if (array[j] != 0x55555555)
#pragma omp atomic
- err++;
+ e++;
}
}
- if (err)
+ if (e)
abort ();
return 0;
}
extern void abort (void);
-int err;
+int e;
void __attribute__((noinline))
foo (int *array)
for (j = 0; j < 40; j++)
if (array[j] != 0x55555555)
#pragma omp atomic
- err++;
+ e++;
}
}
for (i = 0; i < 50; i++)
foo (array);
}
- if (err)
+ if (e)
abort ();
return 0;
}
extern void abort (void);
-int err, a[40];
+int e, a[40];
void __attribute__((noinline))
foo (int *array)
for (j = 0; j < 40; j++)
if (array[j] != 0x55555555)
#pragma omp atomic
- err++;
+ e++;
}
}
for (i = 0; i < 50; i++)
foo (a);
}
- if (err)
+ if (e)
abort ();
return 0;
}
}
int v1 = 1, v2 = 2, v5 = 5;
-int err;
+int e;
void
f2 (void)
#pragma omp parallel num_threads(1) firstprivate(v1, v2, v3, v4)
{
if (++v1 != 8 || ++v2 != 3 || ++v3 != 4 || ++v4 != 5 || ++v5 != 6)
- err = 1;
+ e = 1;
}
if (v1 != 7 || v2 != 2 || v3 != 3 || v4 != 4 || v5 != 6)
abort ();
- if (err)
+ if (e)
abort ();
}
}
}
int v1 = 1, v2 = 2, v5 = 5;
-int err;
+int e;
void
f2 (void)
#pragma omp task
{
if (++v1 != 8 || ++v2 != 3 || ++v3 != 4 || ++v4 != 5 || ++v5 != 6)
- err = 1;
+ e = 1;
}
#pragma omp taskwait
if (v1 != 7 || v2 != 2 || v3 != 3 || v4 != 4 || v5 != 6)
abort ();
- if (err)
+ if (e)
abort ();
}
}
#include <omp.h>
#include <stdlib.h>
-int err;
+int serr;
int
main ()
{
int e;
-#pragma omp parallel shared(err)
+#pragma omp parallel shared(serr)
{
if (omp_in_final ())
#pragma omp atomic write
- err = 1;
- #pragma omp task if (0) shared(err)
+ serr = 1;
+ #pragma omp task if (0) shared(serr)
{
if (omp_in_final ())
#pragma omp atomic write
- err = 1;
- #pragma omp task if (0) shared(err)
+ serr = 1;
+ #pragma omp task if (0) shared(serr)
if (omp_in_final ())
#pragma omp atomic write
- err = 1;
+ serr = 1;
}
- #pragma omp task final (1) shared(err)
+ #pragma omp task final (1) shared(serr)
{
if (!omp_in_final ())
#pragma omp atomic write
- err = 1;
+ serr = 1;
#pragma omp taskyield
#pragma omp taskwait
- #pragma omp task shared(err)
+ #pragma omp task shared(serr)
if (!omp_in_final ())
#pragma omp atomic write
- err = 1;
+ serr = 1;
}
}
#pragma omp atomic read
- e = err;
+ e = serr;
if (e)
abort ();
return 0;