This is the mail archive of the mailing list for the GCC project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [patch] Prefetching dump fixes

On Fri, 10 Nov 2006, Zdenek Dvorak wrote:
> 	* tree-ssa-loop.c (pass_loop_prefetch): Change name to aprefetch.
> 	* tree-ssa-loop-prefetch.c (dump_mem_ref): Fix target file.
> 	(tree_ssa_prefetch_arrays): Do not dump for removed loops.

This is OK for mainline.

However, what do folks think of the following alternate fix?

Index: tree-dump.c
*** tree-dump.c (revision 118585)
--- tree-dump.c (working copy)
*************** dump_switch_p_1 (const char *arg, struct
*** 998,1003 ****
--- 998,1006 ----
    if (!option_value)
      return 0;

+   if (*option_value && *option_value != '-')
+     return 0;
    ptr = option_value;
    flags = 0;

This avoids -fdump-tree-pre from matching -fdump-tree-prefetch by
requiring that the match terminate either with a '\0' or a '-'
separator character.  So "-fdump-tree-pre" and "-fdump-tree-pre-all"
continue to work, but we disallow the contracted "-fdump-tree-preall"
which I suspect is currently accepted by an oversight?

This addresses the problem at it's source, and avoids similar
problems as more passes are added in future.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]