diff options
author | Jan Hubicka <jh@suse.cz> | 2001-11-19 18:08:48 +0100 |
---|---|---|
committer | Jan Hubicka <hubicka@gcc.gnu.org> | 2001-11-19 17:08:48 +0000 |
commit | 7fcd72187907e12fa670d7c4794641691b30e825 (patch) | |
tree | b294c67de998851f229c1f90e61eb62fdc07c65f /gcc/predict.c | |
parent | f83fd9ae2ea1ea580626ed3171c1f5c46a4a05ea (diff) | |
download | gcc-7fcd72187907e12fa670d7c4794641691b30e825.zip gcc-7fcd72187907e12fa670d7c4794641691b30e825.tar.gz gcc-7fcd72187907e12fa670d7c4794641691b30e825.tar.bz2 |
gcse.c (try_replace_reg): Copy RTX before creating note.
* gcse.c (try_replace_reg): Copy RTX before creating note.
* df.h (df_ref_flags): New uenum.
(DF_REF_FLAGS): New macro.
(struct ref): Add field "flags".
* df.c (HANDLE_SUBREG): Remove.
(df_ref_create): Likewise; set flags field of ref.
(df_def_record_1): Strip down read_write subreg; remove
commented out code; set READ_WRITE flag.
(read_modify_subreg_p): New static function.
(df_uses_record): Cleanup SET handling; set READ_WRITE flag;
new argument "flags".
(df_insn_refs_record): Update call of df_uses_record.
(df_insn_modify): Avoid #if 0 around comment.
(df_dump): Dump the read/write flag.
* predict.c (propagate_freq): Make cyclic_probability and frequency
volatile
* i386.c (ix86_cc_mode): Accept USE.
* cfgrtl.c (purge_dead_edges): Cleanup EDGE_ABNORMAL flag if computed
jump is turned into simplejump.
From-SVN: r47175
Diffstat (limited to 'gcc/predict.c')
-rw-r--r-- | gcc/predict.c | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/gcc/predict.c b/gcc/predict.c index c5cc0a4..dacefbe 100644 --- a/gcc/predict.c +++ b/gcc/predict.c @@ -602,7 +602,7 @@ expected_value_to_br_prob () typedef struct block_info_def { /* Estimated frequency of execution of basic_block. */ - double frequency; + volatile double frequency; /* To keep queue of basic blocks to process. */ basic_block next; @@ -619,8 +619,11 @@ typedef struct edge_info_def { /* In case edge is an loopback edge, the probability edge will be reached in case header is. Estimated number of iterations of the loop can be - then computed as 1 / (1 - back_edge_prob). */ - double back_edge_prob; + then computed as 1 / (1 - back_edge_prob). + + Volatile is needed to avoid differences in the optimized and unoptimized + builds on machines where FP registers are wider than double. */ + volatile double back_edge_prob; /* True if the edge is an loopback edge in the natural loop. */ int back_edge:1; } *edge_info; @@ -663,7 +666,7 @@ propagate_freq (head) BLOCK_INFO (head)->frequency = 1; for (; bb; bb = nextbb) { - double cyclic_probability = 0, frequency = 0; + volatile double cyclic_probability = 0, frequency = 0; nextbb = BLOCK_INFO (bb)->next; BLOCK_INFO (bb)->next = NULL; |