aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@redhat.com>2016-01-26 12:12:03 +0100
committerJakub Jelinek <jakub@gcc.gnu.org>2016-01-26 12:12:03 +0100
commit6c06e0e822db96b71c80e268260d2b4b4c1bc1f5 (patch)
tree13dabb40608100e7283aa3ad638031f8b5807728 /gcc/testsuite
parentb96824c4848d33c8cc9b574ce29da98464feaabb (diff)
downloadgcc-6c06e0e822db96b71c80e268260d2b4b4c1bc1f5.zip
gcc-6c06e0e822db96b71c80e268260d2b4b4c1bc1f5.tar.gz
gcc-6c06e0e822db96b71c80e268260d2b4b4c1bc1f5.tar.bz2
re PR target/69442 (wrong code with -Og and 64bit modulo @ armv7a)
PR target/69442 * combine.c (combine_instructions): For REG_EQUAL note with SET_DEST being ZERO_EXTRACT, also temporarily set SET_DEST to the underlying register. * doc/rtl.texi (REG_EQUAL): Document the behavior of REG_EQUAL/REG_EQUIV notes if SET_DEST is ZERO_EXTRACT. * gcc.dg/pr69442.c: New test. From-SVN: r232819
Diffstat (limited to 'gcc/testsuite')
-rw-r--r--gcc/testsuite/ChangeLog5
-rw-r--r--gcc/testsuite/gcc.dg/pr69442.c23
2 files changed, 28 insertions, 0 deletions
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog
index ae150ba..67bc4e4 100644
--- a/gcc/testsuite/ChangeLog
+++ b/gcc/testsuite/ChangeLog
@@ -1,3 +1,8 @@
+2016-01-26 Jakub Jelinek <jakub@redhat.com>
+
+ PR target/69442
+ * gcc.dg/pr69442.c: New test.
+
2016-01-26 Roger Ferrer Ibáñez <rofirrim@gmail.com>
PR target/67896
diff --git a/gcc/testsuite/gcc.dg/pr69442.c b/gcc/testsuite/gcc.dg/pr69442.c
new file mode 100644
index 0000000..ee75f92
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/pr69442.c
@@ -0,0 +1,23 @@
+/* PR target/69442 */
+/* { dg-do run } */
+/* { dg-options "-Og" } */
+
+unsigned long long __attribute__ ((noinline, noclone))
+foo (unsigned int x, unsigned long long y)
+{
+ x |= 0xffff;
+ y -= 0xffULL;
+ y %= 0xffff0000ffffffe7ULL;
+ return x + y;
+}
+
+int
+main ()
+{
+ if (sizeof (unsigned long long) * __CHAR_BIT__ != 64)
+ return 0;
+
+ if (foo (0, 0) != 0xffff0000ff19ULL)
+ __builtin_abort ();
+ return 0;
+}