Fix dump message issue

Message ID d6b78982-e668-992b-da48-a19767801c19@linux.ibm.com
State New
Headers show
Series
  • Fix dump message issue
Related show

Commit Message

luoxhu Oct. 8, 2019, 8:58 a.m.
'}' is missed at the end.

gcc/ChangeLog:
	tree-sra.c (dump_access): Add missing braces.
---
 gcc/tree-sra.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

-- 
2.21.0.777.g83232e3864

Comments

Martin Jambor Oct. 8, 2019, 10:45 a.m. | #1
Hi,

On Tue, Oct 08 2019, luoxhu wrote:
> '}' is missed at the end.


heh, yeah, I wonder for how long.

If it irritates you, I'd say the patch is obvious (though note that I
cannot approve a patch in this area).

Thanks,

Martin


>

> gcc/ChangeLog:

> 	tree-sra.c (dump_access): Add missing braces.

> ---

>  gcc/tree-sra.c | 4 ++--

>  1 file changed, 2 insertions(+), 2 deletions(-)

>

> diff --git a/gcc/tree-sra.c b/gcc/tree-sra.c

> index 48589323a1e..cb59b91f20e 100644

> --- a/gcc/tree-sra.c

> +++ b/gcc/tree-sra.c

> @@ -403,7 +403,7 @@ dump_access (FILE *f, struct access *access, bool grp)

>  	     "grp_hint = %d, grp_covered = %d, "

>  	     "grp_unscalarizable_region = %d, grp_unscalarized_data = %d, "

>  	     "grp_same_access_path = %d, grp_partial_lhs = %d, "

> -	     "grp_to_be_replaced = %d, grp_to_be_debug_replaced = %d\n",

> +	     "grp_to_be_replaced = %d, grp_to_be_debug_replaced = %d}\n",

>  	     access->grp_read, access->grp_write, access->grp_assignment_read,

>  	     access->grp_assignment_write, access->grp_scalar_read,

>  	     access->grp_scalar_write, access->grp_total_scalarization,

> @@ -413,7 +413,7 @@ dump_access (FILE *f, struct access *access, bool grp)

>  	     access->grp_to_be_replaced, access->grp_to_be_debug_replaced);

>    else

>      fprintf (f, ", write = %d, grp_total_scalarization = %d, "

> -	     "grp_partial_lhs = %d\n",

> +	     "grp_partial_lhs = %d}\n",

>  	     access->write, access->grp_total_scalarization,

>  	     access->grp_partial_lhs);

>  }

> -- 

> 2.21.0.777.g83232e3864
Jeff Law Oct. 13, 2019, 4:32 p.m. | #2
On 10/8/19 4:45 AM, Martin Jambor wrote:
> Hi,

> 

> On Tue, Oct 08 2019, luoxhu wrote:

>> '}' is missed at the end.

> 

> heh, yeah, I wonder for how long.

> 

> If it irritates you, I'd say the patch is obvious (though note that I

> cannot approve a patch in this area).

Looks obvious to me.  And while you may not be an official reviewer
Martin, if you say someone's code looks good to you, I'm just going to
rubber stamp it.

Which in turn means you ought to be a reviewer.

Jeff
luoxhu Oct. 14, 2019, 2:07 a.m. | #3
On 2019/10/14 00:32, Jeff Law wrote:
> On 10/8/19 4:45 AM, Martin Jambor wrote:

>> Hi,

>>

>> On Tue, Oct 08 2019, luoxhu wrote:

>>> '}' is missed at the end.

>>

>> heh, yeah, I wonder for how long.

>>

>> If it irritates you, I'd say the patch is obvious (though note that I

>> cannot approve a patch in this area).

> Looks obvious to me.  And while you may not be an official reviewer

> Martin, if you say someone's code looks good to you, I'm just going to

> rubber stamp it.

> 

> Which in turn means you ought to be a reviewer.


Thanks, Martin and Jeff:

It was introduced since the initial commit in 2009:

8d53b873fdce (jamborm   2009-05-29 16:47:31 +0000  277)     fprintf (f, ", write = %d, grp_partial_lhs = %d\n", access->write,

and:

c79d6ecf5563 (jamborm   2009-09-02 17:52:18 +0000  271) "grp_to_be_replaced = %d\n", 

Commited in r276948.


Xiong Hu
BR

> 

> Jeff

>

Patch

diff --git a/gcc/tree-sra.c b/gcc/tree-sra.c
index 48589323a1e..cb59b91f20e 100644
--- a/gcc/tree-sra.c
+++ b/gcc/tree-sra.c
@@ -403,7 +403,7 @@  dump_access (FILE *f, struct access *access, bool grp)
 	     "grp_hint = %d, grp_covered = %d, "
 	     "grp_unscalarizable_region = %d, grp_unscalarized_data = %d, "
 	     "grp_same_access_path = %d, grp_partial_lhs = %d, "
-	     "grp_to_be_replaced = %d, grp_to_be_debug_replaced = %d\n",
+	     "grp_to_be_replaced = %d, grp_to_be_debug_replaced = %d}\n",
 	     access->grp_read, access->grp_write, access->grp_assignment_read,
 	     access->grp_assignment_write, access->grp_scalar_read,
 	     access->grp_scalar_write, access->grp_total_scalarization,
@@ -413,7 +413,7 @@  dump_access (FILE *f, struct access *access, bool grp)
 	     access->grp_to_be_replaced, access->grp_to_be_debug_replaced);
   else
     fprintf (f, ", write = %d, grp_total_scalarization = %d, "
-	     "grp_partial_lhs = %d\n",
+	     "grp_partial_lhs = %d}\n",
 	     access->write, access->grp_total_scalarization,
 	     access->grp_partial_lhs);
 }