Patchwork Add block debug info to phi_arg_d

login
register
mail settings
Submitter Dehao Chen
Date July 8, 2012, 7:29 a.m.
Message ID <CAO2gOZVmnYtpnXKf8SbAJESXL6yeo5UY+43ANEkiWjOt0Cge2A@mail.gmail.com>
Download mbox | patch
Permalink /patch/169623/
State New
Headers show

Comments

Dehao Chen - July 8, 2012, 7:29 a.m.
Hi, Richard,

A test is added. Is it ok?

Thanks,
Dehao

gcc/testsuite/ChangeLog

2012-07-08  Dehao Chen  <dehao@google.com>

        * gcc.dg/debug_info_inline.c: New test.
Richard Guenther - July 9, 2012, 8:14 a.m.
On Sun, Jul 8, 2012 at 9:29 AM, Dehao Chen <dehao@google.com> wrote:
> Hi, Richard,
>
> A test is added. Is it ok?

Ok.

Thanks,
RIchard.

> Thanks,
> Dehao
>
> gcc/testsuite/ChangeLog
>
> 2012-07-08  Dehao Chen  <dehao@google.com>
>
>         * gcc.dg/debug_info_inline.c: New test.
>
> Index: gcc/testsuite/gcc.dg/debug_info_inline.c
> ===================================================================
> --- gcc/testsuite/gcc.dg/debug_info_inline.c    (revision 0)
> +++ gcc/testsuite/gcc.dg/debug_info_inline.c    (revision 0)
> @@ -0,0 +1,24 @@
> +/* { dg-do compile } */
> +/* { dg-options "-O2 -g" } */
> +
> +int g, a;
> +
> +static int foo ()
> +{
> +  int ret = a;
> +
> +  if (g > -10)
> +    return 10;
> +
> +  return ret;
> +}
> +
> +int bar()
> +{
> +  if (foo())
> +    return 0;
> +  else
> +    return 1;
> +}
> +
> +/* { dg-final { scan-assembler "loc 1 19 0\n.*\n.LBB" } } */

Patch

Index: gcc/testsuite/gcc.dg/debug_info_inline.c
===================================================================
--- gcc/testsuite/gcc.dg/debug_info_inline.c	(revision 0)
+++ gcc/testsuite/gcc.dg/debug_info_inline.c	(revision 0)
@@ -0,0 +1,24 @@ 
+/* { dg-do compile } */
+/* { dg-options "-O2 -g" } */
+
+int g, a;
+
+static int foo ()
+{
+  int ret = a;
+
+  if (g > -10)
+    return 10;
+
+  return ret;
+}
+
+int bar()
+{
+  if (foo())
+    return 0;
+  else
+    return 1;
+}
+
+/* { dg-final { scan-assembler "loc 1 19 0\n.*\n.LBB" } } */