[AArch64][SVE 02/32] Avoid hard-coded limit in indented_print
The maximum indentation needed by aarch64-gen.c grows as more instructions are added to aarch64-tbl.h. Rather than having to increase the indentation limit to a higher value, it seemed better to replace it with "%*s". opcodes/ * aarch64-gen.c (indented_print): Avoid hard-coded indentation limit.
This commit is contained in:
parent
a235d3aece
commit
bd11d5d837
|
@ -1,3 +1,7 @@
|
||||||
|
2016-09-21 Richard Sandiford <richard.sandiford@arm.com>
|
||||||
|
|
||||||
|
* aarch64-gen.c (indented_print): Avoid hard-coded indentation limit.
|
||||||
|
|
||||||
2016-09-15 Claudiu Zissulescu <claziss@synopsys.com>
|
2016-09-15 Claudiu Zissulescu <claziss@synopsys.com>
|
||||||
|
|
||||||
* arc-dis.c (find_format): Walk the linked list pointed by einsn.
|
* arc-dis.c (find_format): Walk the linked list pointed by einsn.
|
||||||
|
|
|
@ -378,13 +378,9 @@ initialize_decoder_tree (void)
|
||||||
static void __attribute__ ((format (printf, 2, 3)))
|
static void __attribute__ ((format (printf, 2, 3)))
|
||||||
indented_print (unsigned int indent, const char *format, ...)
|
indented_print (unsigned int indent, const char *format, ...)
|
||||||
{
|
{
|
||||||
/* 80 number of spaces pluc a NULL terminator. */
|
|
||||||
static const char spaces[81] =
|
|
||||||
" ";
|
|
||||||
va_list ap;
|
va_list ap;
|
||||||
va_start (ap, format);
|
va_start (ap, format);
|
||||||
assert (indent <= 80);
|
printf ("%*s", (int) indent, "");
|
||||||
printf ("%s", &spaces[80 - indent]);
|
|
||||||
vprintf (format, ap);
|
vprintf (format, ap);
|
||||||
va_end (ap);
|
va_end (ap);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue