re PR target/49866 (-mcmodel=large tail call fails to assemble)
authorJakub Jelinek <jakub@redhat.com>
Wed, 27 Jul 2011 18:19:40 +0000 (20:19 +0200)
committerJakub Jelinek <jakub@gcc.gnu.org>
Wed, 27 Jul 2011 18:19:40 +0000 (20:19 +0200)
PR target/49866
* gcc.target/i386/pr49866.c: New test.

From-SVN: r176842

gcc/testsuite/ChangeLog
gcc/testsuite/gcc.target/i386/pr49866.c [new file with mode: 0644]

index 30c86efa598d3f158f6bef68b0bfcdf28ea0d042..a5fd846f32eeaac1b4c5ac4ce4742ccc8b7a2b1e 100644 (file)
@@ -1,3 +1,8 @@
+2011-07-27  Jakub Jelinek  <jakub@redhat.com>
+
+       PR target/49866
+       * gcc.target/i386/pr49866.c: New test.
+
 2011-07-27  Yukhin Kirill  <kirill.yukhin@intel.com>
 
        * gcc.target/i386/i386.exp (check_effective_target_bmi): New.
diff --git a/gcc/testsuite/gcc.target/i386/pr49866.c b/gcc/testsuite/gcc.target/i386/pr49866.c
new file mode 100644 (file)
index 0000000..823305d
--- /dev/null
@@ -0,0 +1,23 @@
+/* PR target/49866 */
+/* { dg-do assemble } */
+/* { dg-options "-O2 -mcmodel=large" { target lp64 } } */
+
+void fn (void *, int, int);
+int fn2 (void);
+void baz (int);
+
+static void
+foo (void *x, int y)
+{
+  int i;
+  for (i = 0; i < y; i++)
+    fn (x, fn2 (), i);
+}
+
+void
+bar (int u, int v, int w, void *x)
+{
+  baz (u);
+  foo (x, w);
+  baz (u);
+}