This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[committed] Add testcase from PR57131


Hi!

This got fixed by Vlad in PR57097, I've committed the testcase as obvious
(so far to trunk, because the fix hasn't been backported to 4.8 branch yet,
will commit there too afterwards).

2013-05-02  Jakub Jelinek  <jakub@redhat.com>

	PR rtl-optimization/57131
	* gcc.c-torture/execute/pr57131.c: New test.

--- gcc/testsuite/gcc.c-torture/execute/pr57131.c.jj	2013-05-02 07:58:05.557803157 +0200
+++ gcc/testsuite/gcc.c-torture/execute/pr57131.c	2013-05-02 07:54:14.000000000 +0200
@@ -0,0 +1,19 @@
+/* PR rtl-optimization/57131 */
+
+extern void abort (void);
+
+int
+main ()
+{
+  volatile int x1 = 0;
+  volatile long long x2 = 0;
+  volatile int x3 = 0;
+  volatile int x4 = 1;
+  volatile int x5 = 1;
+  volatile long long x6 = 1;
+  long long t = ((x1 * (x2 << x3)) / (x4 * x5)) + x6;
+
+  if (t != 1)
+    abort ();
+  return 0;
+}

	Jakub


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]