Commit 4a3c9687 by Bernd Schmidt Committed by Bernd Schmidt

tree-dump.c (dump_option_value_info): Add entry for TDF_CSELIB.

	* tree-dump.c (dump_option_value_info): Add entry for TDF_CSELIB.
	* tree-pass.h (TDF_CSELIB): New macro.
	* cselib.c (new_cselib_val, expand_loc, cselib_expand_value_rtx_1,
	cselib_lookup): Check for it rather than for TDF_DETAILS.

From-SVN: r169482
parent 0f0a4367
2011-02-01 Bernd Schmidt <bernds@codesourcery.com>
* tree-dump.c (dump_option_value_info): Add entry for TDF_CSELIB.
* tree-pass.h (TDF_CSELIB): New macro.
* cselib.c (new_cselib_val, expand_loc, cselib_expand_value_rtx_1,
cselib_lookup): Check for it rather than for TDF_DETAILS.
2011-02-01 H.J. Lu <hongjiu.lu@intel.com> 2011-02-01 H.J. Lu <hongjiu.lu@intel.com>
PR driver/47547 PR driver/47547
......
/* Common subexpression elimination library for GNU compiler. /* Common subexpression elimination library for GNU compiler.
Copyright (C) 1987, 1988, 1989, 1992, 1993, 1994, 1995, 1996, 1997, 1998, Copyright (C) 1987, 1988, 1989, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
1999, 2000, 2001, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 1999, 2000, 2001, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011
Free Software Foundation, Inc. Free Software Foundation, Inc.
This file is part of GCC. This file is part of GCC.
...@@ -1015,7 +1015,7 @@ new_cselib_val (unsigned int hash, enum machine_mode mode, rtx x) ...@@ -1015,7 +1015,7 @@ new_cselib_val (unsigned int hash, enum machine_mode mode, rtx x)
e->locs = 0; e->locs = 0;
e->next_containing_mem = 0; e->next_containing_mem = 0;
if (dump_file && (dump_flags & TDF_DETAILS)) if (dump_file && (dump_flags & TDF_CSELIB))
{ {
fprintf (dump_file, "cselib value %u:%u ", e->uid, hash); fprintf (dump_file, "cselib value %u:%u ", e->uid, hash);
if (flag_dump_noaddr || flag_dump_unnumbered) if (flag_dump_noaddr || flag_dump_unnumbered)
...@@ -1132,7 +1132,7 @@ expand_loc (struct elt_loc_list *p, struct expand_value_data *evd, ...@@ -1132,7 +1132,7 @@ expand_loc (struct elt_loc_list *p, struct expand_value_data *evd,
else if (!REG_P (p->loc)) else if (!REG_P (p->loc))
{ {
rtx result, note; rtx result, note;
if (dump_file && (dump_flags & TDF_DETAILS)) if (dump_file && (dump_flags & TDF_CSELIB))
{ {
print_inline_rtx (dump_file, p->loc, 0); print_inline_rtx (dump_file, p->loc, 0);
fprintf (dump_file, "\n"); fprintf (dump_file, "\n");
...@@ -1153,7 +1153,7 @@ expand_loc (struct elt_loc_list *p, struct expand_value_data *evd, ...@@ -1153,7 +1153,7 @@ expand_loc (struct elt_loc_list *p, struct expand_value_data *evd,
if (regno != UINT_MAX) if (regno != UINT_MAX)
{ {
rtx result; rtx result;
if (dump_file && (dump_flags & TDF_DETAILS)) if (dump_file && (dump_flags & TDF_CSELIB))
fprintf (dump_file, "r%d\n", regno); fprintf (dump_file, "r%d\n", regno);
result = cselib_expand_value_rtx_1 (reg_result, evd, max_depth - 1); result = cselib_expand_value_rtx_1 (reg_result, evd, max_depth - 1);
...@@ -1161,7 +1161,7 @@ expand_loc (struct elt_loc_list *p, struct expand_value_data *evd, ...@@ -1161,7 +1161,7 @@ expand_loc (struct elt_loc_list *p, struct expand_value_data *evd,
return result; return result;
} }
if (dump_file && (dump_flags & TDF_DETAILS)) if (dump_file && (dump_flags & TDF_CSELIB))
{ {
if (reg_result) if (reg_result)
{ {
...@@ -1302,7 +1302,7 @@ cselib_expand_value_rtx_1 (rtx orig, struct expand_value_data *evd, ...@@ -1302,7 +1302,7 @@ cselib_expand_value_rtx_1 (rtx orig, struct expand_value_data *evd,
bitmap_set_bit (evd->regs_active, regno); bitmap_set_bit (evd->regs_active, regno);
if (dump_file && (dump_flags & TDF_DETAILS)) if (dump_file && (dump_flags & TDF_CSELIB))
fprintf (dump_file, "expanding: r%d into: ", regno); fprintf (dump_file, "expanding: r%d into: ", regno);
result = expand_loc (l->elt->locs, evd, max_depth); result = expand_loc (l->elt->locs, evd, max_depth);
...@@ -1367,7 +1367,7 @@ cselib_expand_value_rtx_1 (rtx orig, struct expand_value_data *evd, ...@@ -1367,7 +1367,7 @@ cselib_expand_value_rtx_1 (rtx orig, struct expand_value_data *evd,
{ {
rtx result; rtx result;
if (dump_file && (dump_flags & TDF_DETAILS)) if (dump_file && (dump_flags & TDF_CSELIB))
{ {
fputs ("\nexpanding ", dump_file); fputs ("\nexpanding ", dump_file);
print_rtl_single (dump_file, orig); print_rtl_single (dump_file, orig);
...@@ -1736,7 +1736,7 @@ cselib_lookup (rtx x, enum machine_mode mode, int create) ...@@ -1736,7 +1736,7 @@ cselib_lookup (rtx x, enum machine_mode mode, int create)
easiest setting cselib_current_insn to NULL before the call easiest setting cselib_current_insn to NULL before the call
above. */ above. */
if (dump_file && (dump_flags & TDF_DETAILS)) if (dump_file && (dump_flags & TDF_CSELIB))
{ {
fputs ("cselib lookup ", dump_file); fputs ("cselib lookup ", dump_file);
print_inline_rtx (dump_file, x, 2); print_inline_rtx (dump_file, x, 2);
......
/* Tree-dumping functionality for intermediate representation. /* Tree-dumping functionality for intermediate representation.
Copyright (C) 1999, 2000, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, Copyright (C) 1999, 2000, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009,
2010 Free Software Foundation, Inc. 2010, 2011 Free Software Foundation, Inc.
Written by Mark Mitchell <mark@codesourcery.com> Written by Mark Mitchell <mark@codesourcery.com>
This file is part of GCC. This file is part of GCC.
...@@ -814,6 +814,7 @@ static const struct dump_option_value_info dump_options[] = ...@@ -814,6 +814,7 @@ static const struct dump_option_value_info dump_options[] =
{"raw", TDF_RAW}, {"raw", TDF_RAW},
{"graph", TDF_GRAPH}, {"graph", TDF_GRAPH},
{"details", TDF_DETAILS}, {"details", TDF_DETAILS},
{"cselib", TDF_CSELIB},
{"stats", TDF_STATS}, {"stats", TDF_STATS},
{"blocks", TDF_BLOCKS}, {"blocks", TDF_BLOCKS},
{"vops", TDF_VOPS}, {"vops", TDF_VOPS},
......
/* Definitions for describing one tree-ssa optimization pass. /* Definitions for describing one tree-ssa optimization pass.
Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010 Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011
Free Software Foundation, Inc. Free Software Foundation, Inc.
Contributed by Richard Henderson <rth@redhat.com> Contributed by Richard Henderson <rth@redhat.com>
...@@ -82,6 +82,7 @@ enum tree_dump_index ...@@ -82,6 +82,7 @@ enum tree_dump_index
#define TDF_NOUID (1 << 20) /* omit UIDs from dumps. */ #define TDF_NOUID (1 << 20) /* omit UIDs from dumps. */
#define TDF_ALIAS (1 << 21) /* display alias information */ #define TDF_ALIAS (1 << 21) /* display alias information */
#define TDF_ENUMERATE_LOCALS (1 << 22) /* Enumerate locals by uid. */ #define TDF_ENUMERATE_LOCALS (1 << 22) /* Enumerate locals by uid. */
#define TDF_CSELIB (1 << 23) /* Dump cselib details. */
/* In tree-dump.c */ /* In tree-dump.c */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment