Hi,
As reported in PR 61367, the aarch64 back-end is too verbose when it
is dealing with the cost model. I tend to agree, no other back-end is
this verbose. So I decided to add an option to enable this verbose
output if requested.
I did NOT document it in invoke.texi because I don't feel like this is
an option which an user should use. But I can add it if requested.
OK? Bootstrapped and tested on aarch64-linux-gnu with no regressions.
Thanks,
Andrew Pinski
ChangeLog:
* config/aarch64/aarch64.opt (mverbose-cost-dump): New option.
* config/aarch64/aarch64.c (aarch64_rtx_costs): Use
flag_aarch64_verbose_cost instead of checking for details dump.
(aarch64_rtx_costs_wrapper): Likewise.
Index: config/aarch64/aarch64.c
===================================================================
--- config/aarch64/aarch64.c (revision 240461)
+++ config/aarch64/aarch64.c (working copy)
@@ -7351,7 +7351,8 @@
break;
}
- if (dump_file && (dump_flags & TDF_DETAILS))
+ if (dump_file
+ && flag_aarch64_verbose_cost)
fprintf (dump_file,
"\nFailed to cost RTX. Assuming default cost.\n");
@@ -7367,7 +7368,8 @@
{
bool result = aarch64_rtx_costs (x, mode, outer, param, cost, speed);
- if (dump_file && (dump_flags & TDF_DETAILS))
+ if (dump_file
+ && flag_aarch64_verbose_cost)
{
print_rtl_single (dump_file, x);
fprintf (dump_file, "\n%s cost: %d (%s)\n",
Index: config/aarch64/aarch64.opt
===================================================================
--- config/aarch64/aarch64.opt (revision 240461)
+++ config/aarch64/aarch64.opt (working copy)
@@ -167,3 +167,7 @@
Enable the division approximation. Enabling this reduces
precision of division results to about 16 bits for
single precision and to 32 bits for double precision.
+
+mverbose-cost-dump
+Common Var(flag_aarch64_verbose_cost)
+Enables verbose cost model dummping in the debug dump files.