From: Jakub Jelinek Date: Mon, 25 Feb 2019 22:58:45 +0000 (+0100) Subject: re PR c/77754 (internal compiler error : tree code 'call_expr' is not supported in... X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=796954501274027ac9ba69b8c7f8eb08339f51ac;p=gcc.git re PR c/77754 (internal compiler error : tree code 'call_expr' is not supported in LTO streams) PR c/77754 * gcc.c-torture/compile/pr77754-1.c: New test. * gcc.c-torture/compile/pr77754-2.c: New test. * gcc.c-torture/compile/pr77754-3.c: New test. * gcc.c-torture/compile/pr77754-4.c: New test. * gcc.c-torture/compile/pr77754-5.c: New test. * gcc.c-torture/compile/pr77754-6.c: New test. From-SVN: r269197 --- diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 3e89a7d09cb..dcd7c674307 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,13 @@ +2019-02-25 Jakub Jelinek + + PR c/77754 + * gcc.c-torture/compile/pr77754-1.c: New test. + * gcc.c-torture/compile/pr77754-2.c: New test. + * gcc.c-torture/compile/pr77754-3.c: New test. + * gcc.c-torture/compile/pr77754-4.c: New test. + * gcc.c-torture/compile/pr77754-5.c: New test. + * gcc.c-torture/compile/pr77754-6.c: New test. + 2019-02-25 Tamar Christina PR target/88530 diff --git a/gcc/testsuite/gcc.c-torture/compile/pr77754-1.c b/gcc/testsuite/gcc.c-torture/compile/pr77754-1.c new file mode 100644 index 00000000000..48587f7ca69 --- /dev/null +++ b/gcc/testsuite/gcc.c-torture/compile/pr77754-1.c @@ -0,0 +1,11 @@ +/* PR c/77754 */ + +int fn3(); + +void fn4(int[][fn3 ()]); + +void fn1() { + void fn2(int[][fn3 ()]); + int a[10][fn3 ()]; + fn4 (a); +} diff --git a/gcc/testsuite/gcc.c-torture/compile/pr77754-2.c b/gcc/testsuite/gcc.c-torture/compile/pr77754-2.c new file mode 100644 index 00000000000..411f270a16a --- /dev/null +++ b/gcc/testsuite/gcc.c-torture/compile/pr77754-2.c @@ -0,0 +1,10 @@ +/* PR c/77754 */ + +int fn3(); + +void (**fn5) (int[][fn3 ()]); + +void fn1 () { + int a[10][fn3 ()]; + (**fn5) (a); +} diff --git a/gcc/testsuite/gcc.c-torture/compile/pr77754-3.c b/gcc/testsuite/gcc.c-torture/compile/pr77754-3.c new file mode 100644 index 00000000000..c6ff9606200 --- /dev/null +++ b/gcc/testsuite/gcc.c-torture/compile/pr77754-3.c @@ -0,0 +1,11 @@ +/* PR c/77754 */ + +int fn3(); + +typedef void (*fn6) (int[][fn3 ()]); +fn6 **fn7; + +void fn1 () { + int a[10][fn3 ()]; + (**fn7) (a); +} diff --git a/gcc/testsuite/gcc.c-torture/compile/pr77754-4.c b/gcc/testsuite/gcc.c-torture/compile/pr77754-4.c new file mode 100644 index 00000000000..f0274051ad0 --- /dev/null +++ b/gcc/testsuite/gcc.c-torture/compile/pr77754-4.c @@ -0,0 +1,17 @@ +/* PR c/77754 */ + +int fn3(); + +typedef void (*fn6) (int[][fn3 ()]); +struct S { + fn6 **fn7; + fn6 *fn8; + fn6 fn9; +} s; + +void fn1 () { + int a[10][fn3 ()]; + (**s.fn7) (a); + (*s.fn8) (a); + s.fn9 (a); +} diff --git a/gcc/testsuite/gcc.c-torture/compile/pr77754-5.c b/gcc/testsuite/gcc.c-torture/compile/pr77754-5.c new file mode 100644 index 00000000000..a9440ddb1fa --- /dev/null +++ b/gcc/testsuite/gcc.c-torture/compile/pr77754-5.c @@ -0,0 +1,14 @@ +/* PR c/77754 */ + +int fn3(); + +void fn4(int[][fn3 ()]); +void fn4(int x[][fn3 ()]) +{ +} + +void fn1() { + void fn2(int[][fn3 ()]); + int a[10][fn3 ()]; + fn4 (a); +} diff --git a/gcc/testsuite/gcc.c-torture/compile/pr77754-6.c b/gcc/testsuite/gcc.c-torture/compile/pr77754-6.c new file mode 100644 index 00000000000..2e7df3b6774 --- /dev/null +++ b/gcc/testsuite/gcc.c-torture/compile/pr77754-6.c @@ -0,0 +1,10 @@ +/* PR c/77754 */ + +int fn3(); + +void fn4(int (*)[fn3 ()][fn3 () + 1][fn3 () + 2], struct S { int a[fn3 ()]; } *); + +void fn1() { + int a[10][fn3 ()][fn3 () + 1][fn3 () + 2]; + fn4 (a, 0); +}