This is the mail archive of the
mailing list for the GCC project.
Re: [patch] Prefetching dump fixes
- From: Roger Sayle <roger at eyesopen dot com>
- To: Zdenek Dvorak <rakdver at atrey dot karlin dot mff dot cuni dot cz>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Thu, 9 Nov 2006 17:45:13 -0700 (MST)
- Subject: 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?
*** 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 && *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.