[gcc/devel/ranger] arc: Cleanup compilation warning

Aldy Hernandez aldyh@gcc.gnu.org
Wed Jun 17 20:04:35 GMT 2020


https://gcc.gnu.org/g:d08a318b4fdf92f6e57116349f37195fbc085b9e

commit d08a318b4fdf92f6e57116349f37195fbc085b9e
Author: Claudiu Zissulescu <claziss@gmail.com>
Date:   Tue Mar 31 15:00:04 2020 +0300

    arc: Cleanup compilation warning
    
    gcc/
    xxxx-xx-xx  Claudiu Zissulescu  <claziss@synopsys.com>
    
            * config/arc/arc.h (ASM_FORMAT_PRIVATE_NAME): Fix it.

Diff:
---
 gcc/ChangeLog        | 6 +++++-
 gcc/config/arc/arc.h | 6 +++---
 2 files changed, 8 insertions(+), 4 deletions(-)

diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 928c7939925..9da7a4a76b7 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,10 +1,14 @@
+2020-03-31  Claudiu Zissulescu  <claziss@synopsys.com>
+
+	* config/arc/arc.h (ASM_FORMAT_PRIVATE_NAME): Fix it.
+
 2020-03-31  Srinath Parvathaneni  <srinath.parvathaneni@arm.com>
 
 	* config/arm/arm_mve.h (vbicq): Define MVE intrinsic polymorphic
 	variant.
 	(__arm_vbicq): Likewise.
 
-2020-0-31  Vineet Gupta <vgupta@synopsys.com>
+2020-03-31  Vineet Gupta <vgupta@synopsys.com>
 
 	* config/arc/linux.h: GLIBC_DYNAMIC_LINKER support BE/arc700.
 
diff --git a/gcc/config/arc/arc.h b/gcc/config/arc/arc.h
index be1d5cb21e7..fd6e21adfaa 100644
--- a/gcc/config/arc/arc.h
+++ b/gcc/config/arc/arc.h
@@ -1136,9 +1136,9 @@ do {							\
 /* Store in OUTPUT a string (made with alloca) containing
    an assembler-name for a local static variable named NAME.
    LABELNO is an integer which is different for each call.  */
-#define ASM_FORMAT_PRIVATE_NAME(OUTPUT, NAME, LABELNO) \
-( (OUTPUT) = (char *) alloca (strlen ((NAME)) + 10),	\
-  sprintf ((OUTPUT), "%s.%d", (NAME), (LABELNO)))
+#define ASM_FORMAT_PRIVATE_NAME(OUTPUT, NAME, LABELNO)			\
+  ((OUTPUT) = (char *) alloca (strlen ((NAME)) + 10),			\
+   sprintf ((OUTPUT), "%s.%u", (NAME), (unsigned int)(LABELNO)))
 
 /* The following macro defines the format used to output the second
    operand of the .type assembler directive.  Different svr4 assemblers


More information about the Gcc-cvs mailing list