Commit 05c219bb by Paolo Bonzini

df-core.c: Update comments referring to removed features.

2007-12-14  Paolo Bonzini  <bonzini@gnu.org>

	* df-core.c: Update comments referring to removed features.
	* df-problems.c: Likewise.
	* df-scan.c: Likewise.
	* df.h: Likewise.

From-SVN: r130937
parent 627eb745
...@@ -71,7 +71,7 @@ USAGE: ...@@ -71,7 +71,7 @@ USAGE:
Here is an example of using the dataflow routines. Here is an example of using the dataflow routines.
df_[ru,rd,urec,ri,chain]_add_problem (flags); df_[chain,live,note,rd]_add_problem (flags);
df_set_blocks (blocks); df_set_blocks (blocks);
...@@ -81,7 +81,7 @@ Here is an example of using the dataflow routines. ...@@ -81,7 +81,7 @@ Here is an example of using the dataflow routines.
df_finish_pass (false); df_finish_pass (false);
DF_[ru,rd,urec,ri,chain]_ADD_PROBLEM adds a problem, defined by an DF_[chain,live,note,rd]_ADD_PROBLEM adds a problem, defined by an
instance to struct df_problem, to the set of problems solved in this instance to struct df_problem, to the set of problems solved in this
instance of df. All calls to add a problem for a given instance of df instance of df. All calls to add a problem for a given instance of df
must occur before the first call to DF_ANALYZE. must occur before the first call to DF_ANALYZE.
...@@ -628,9 +628,9 @@ df_remove_problem (struct dataflow *dflow) ...@@ -628,9 +628,9 @@ df_remove_problem (struct dataflow *dflow)
} }
/* Remove all of the problems that are not permanent. Scanning, lr, /* Remove all of the problems that are not permanent. Scanning, LR
ur and live are permanent, the rest are removable. Also clear all and (at -O2 or higher) LIVE are permanent, the rest are removable.
of the changeable_flags. */ Also clear all of the changeable_flags. */
void void
df_finish_pass (bool verify ATTRIBUTE_UNUSED) df_finish_pass (bool verify ATTRIBUTE_UNUSED)
......
...@@ -1304,16 +1304,22 @@ df_lr_verify_transfer_functions (void) ...@@ -1304,16 +1304,22 @@ df_lr_verify_transfer_functions (void)
/*---------------------------------------------------------------------------- /*----------------------------------------------------------------------------
COMBINED LIVE REGISTERS AND UNINITIALIZED REGISTERS. LIVE AND MUST-INITIALIZED REGISTERS.
First find the set of uses for registers that are reachable from This problem first computes the IN and OUT bitvectors for the
the entry block without passing thru a definition. In and out must-initialized registers problems, which is a forward problem.
bitvectors are built for each basic block. The regnum is used to It gives the set of registers for which we MUST have an available
index into these sets. See df.h for details. definition on any path from the entry block to the entry/exit of
a basic block. Sets generate a definition, while clobbers kill
Then the in and out sets here are the anded results of the in and a definition.
out sets from the lr and ur
problems. In and out bitvectors are built for each basic block and are indexed by
regnum (see df.h for details). In and out bitvectors in struct
df_live_bb_info actually refers to the must-initialized problem;
Then, the in and out sets for the LIVE problem itself are computed.
These are the logical AND of the IN and OUT sets from the LR problem
and the must-initialized problem.
----------------------------------------------------------------------------*/ ----------------------------------------------------------------------------*/
/* Private data used to verify the solution for this problem. */ /* Private data used to verify the solution for this problem. */
...@@ -1510,7 +1516,7 @@ df_live_init (bitmap all_blocks) ...@@ -1510,7 +1516,7 @@ df_live_init (bitmap all_blocks)
} }
} }
/* Confluence function that ignores fake edges. */ /* Forward confluence function that ignores fake edges. */
static void static void
df_live_confluence_n (edge e) df_live_confluence_n (edge e)
...@@ -1525,7 +1531,7 @@ df_live_confluence_n (edge e) ...@@ -1525,7 +1531,7 @@ df_live_confluence_n (edge e)
} }
/* Transfer function. */ /* Transfer function for the forwards must-initialized problem. */
static bool static bool
df_live_transfer_function (int bb_index) df_live_transfer_function (int bb_index)
...@@ -1540,7 +1546,7 @@ df_live_transfer_function (int bb_index) ...@@ -1540,7 +1546,7 @@ df_live_transfer_function (int bb_index)
} }
/* And the LR and UR info to produce the LIVE info. */ /* And the LR info with the must-initialized registers, to produce the LIVE info. */
static void static void
df_live_local_finalize (bitmap all_blocks) df_live_local_finalize (bitmap all_blocks)
...@@ -2916,10 +2922,6 @@ static struct df_problem problem_NOTE = ...@@ -2916,10 +2922,6 @@ static struct df_problem problem_NOTE =
NULL, /* Debugging end block. */ NULL, /* Debugging end block. */
NULL, /* Incremental solution verify start. */ NULL, /* Incremental solution verify start. */
NULL, /* Incremental solution verify end. */ NULL, /* Incremental solution verify end. */
/* Technically this is only dependent on the live registers problem
but it will produce information if built one of uninitialized
register problems (UR, UREC) is also run. */
&problem_LR, /* Dependent problem. */ &problem_LR, /* Dependent problem. */
TV_DF_NOTE, /* Timing variable. */ TV_DF_NOTE, /* Timing variable. */
false /* Reset blocks on dropping out of blocks_to_analyze. */ false /* Reset blocks on dropping out of blocks_to_analyze. */
......
...@@ -3381,7 +3381,7 @@ df_bb_refs_record (int bb_index, bool scan_insns) ...@@ -3381,7 +3381,7 @@ df_bb_refs_record (int bb_index, bool scan_insns)
df_refs_add_to_chains (&collection_rec, bb, NULL); df_refs_add_to_chains (&collection_rec, bb, NULL);
/* Now that the block has been processed, set the block as dirty so /* Now that the block has been processed, set the block as dirty so
lr and ur will get it processed. */ LR and LIVE will get it processed. */
df_set_bb_dirty (bb); df_set_bb_dirty (bb);
} }
......
...@@ -36,10 +36,12 @@ struct df_problem; ...@@ -36,10 +36,12 @@ struct df_problem;
struct df_link; struct df_link;
/* Data flow problems. All problems must have a unique id here. */ /* Data flow problems. All problems must have a unique id here. */
/* Scanning is not really a dataflow problem, but it is useful to have /* Scanning is not really a dataflow problem, but it is useful to have
the basic block functions in the vector so that things get done in the basic block functions in the vector so that things get done in
a uniform manner. The first four problems are always defined. The a uniform manner. The last four problems can be added or deleted
last 5 are optional and can be added or deleted at any time. */ at any time are always defined (though LIVE is always there at -O2
or higher); the others are always there. */
#define DF_SCAN 0 #define DF_SCAN 0
#define DF_LR 1 /* Live Registers backward. */ #define DF_LR 1 /* Live Registers backward. */
#define DF_LIVE 2 /* Live Registers & Uninitialized Registers */ #define DF_LIVE 2 /* Live Registers & Uninitialized Registers */
......
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