From: James Greenhalgh Date: Tue, 17 May 2016 08:54:19 +0000 (+0000) Subject: [AArch64 trivial] Don't define a macro when a variable will do X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=83faf7d007de84b71158051363a70eb1cbffe5a5;p=gcc.git [AArch64 trivial] Don't define a macro when a variable will do * config/aarch64/aarch64.c (aarch64_output_simd_mov_immediate): Make "buf_size" a variable rather than a macro. From-SVN: r236311 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index c854a3e6c5b..44fac540afd 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2016-05-17 James Greenhalgh + + * config/aarch64/aarch64.c + (aarch64_output_simd_mov_immediate): Make "buf_size" a variable + rather than a macro. + 2016-05-16 Wilco Dijkstra * doc/invoke.texi (AArch64 Options): Various updates. diff --git a/gcc/config/aarch64/aarch64.c b/gcc/config/aarch64/aarch64.c index e081b16f324..986262b91ef 100644 --- a/gcc/config/aarch64/aarch64.c +++ b/gcc/config/aarch64/aarch64.c @@ -11845,12 +11845,11 @@ aarch64_output_simd_mov_immediate (rtx const_vector, info.value = GEN_INT (0); else { -#define buf_size 20 + const unsigned int buf_size = 20; char float_buf[buf_size] = {'\0'}; real_to_decimal_for_mode (float_buf, CONST_DOUBLE_REAL_VALUE (info.value), buf_size, buf_size, 1, mode); -#undef buf_size if (lane_count == 1) snprintf (templ, sizeof (templ), "fmov\t%%d0, %s", float_buf);