From: Andrew Pinski Date: Sun, 23 Nov 2014 12:30:24 +0000 (+0000) Subject: 20120927-1.c: New testcase. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=5e383359eac455ec79830a25b81d7b4bc36abc7a;p=gcc.git 20120927-1.c: New testcase. 2014-11-23 Andrew Pinski * gcc.c-torture/compile/20120927-1.c: New testcase. * gcc.c-torture/compile/20120830-1.c: New testcase. From-SVN: r217982 --- diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index e3e9611b662..3d6062fd801 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2014-11-23 Andrew Pinski + + * gcc.c-torture/compile/20120927-1.c: New testcase. + * gcc.c-torture/compile/20120830-1.c: New testcase. + 2014-11-22 Andrew Pinski * g++.dg/cpp0x/initlist-lifetime1.C: Fix testcase where diff --git a/gcc/testsuite/gcc.c-torture/compile/20120830-1.c b/gcc/testsuite/gcc.c-torture/compile/20120830-1.c new file mode 100644 index 00000000000..e0453ca6c52 --- /dev/null +++ b/gcc/testsuite/gcc.c-torture/compile/20120830-1.c @@ -0,0 +1,14 @@ +int keyring_search(void); +int keydb_search2 (int *hdfound, int *hdcurrent, int *a) +{ + int rc = -1; + while (rc == -1) { + if (*a == 1) + rc = keyring_search (); + if (rc == -1) + *hdcurrent++; + if (!rc) + *hdfound = *hdcurrent; + } + return rc; +} diff --git a/gcc/testsuite/gcc.c-torture/compile/20120927-1.c b/gcc/testsuite/gcc.c-torture/compile/20120927-1.c new file mode 100644 index 00000000000..7cf09ead503 --- /dev/null +++ b/gcc/testsuite/gcc.c-torture/compile/20120927-1.c @@ -0,0 +1,43 @@ +void ff(int); +int isc_fsaccess_set(unsigned int access) { + unsigned int mode; + unsigned int bits; + mode = 0; + bits = 0x00000021; + if ((access & bits) != 0) + { + mode |= 0400; + access &= ~bits; + } + access &= ~bits; + bits <<= (10); + if ((access & bits) != 0) + access &= ~bits; + bits = 0x00000012; + if ((access & bits) != 0) + { + mode |= 0200; + access &= ~bits; + } + mode |= (0200 >> 3); + access &= ~bits; + bits <<= (10); + if ((access & bits) != 0) + mode |= ((0200 >> 3) >> 3); + bits = 0x00000044; + if ((access & bits) != 0) + { + mode |= 0100; + access &= ~bits; + } + if ((access & bits) != 0) + { + mode |= (0100 >> 3); + access &= ~bits; + }; + bits <<= (10); + if ((access & bits) != 0) + mode |= ((0100 >> 3) >> 3); + ff(mode) ; +} +