Commit 0bab1c88 by Jeff Law Committed by Jeff Law

tree-ssa-alias.c (compute_flow_insensitive_aliasing): Reduce the number of…

tree-ssa-alias.c (compute_flow_insensitive_aliasing): Reduce the number of queries to random elements in the ai->written_vars bitmap.

        * tree-ssa-alias.c (compute_flow_insensitive_aliasing): Reduce
        the number of queries to random elements in the ai->written_vars
        bitmap.

From-SVN: r91271
parent 36739040
2004-11-24 Jeff Law <law@redhat.com>
* tree-ssa-alias.c (compute_flow_insensitive_aliasing): Reduce
the number of queries to random elements in the ai->written_vars
bitmap.
2004-11-24 Roger Sayle <roger@eyesopen.com> 2004-11-24 Roger Sayle <roger@eyesopen.com>
* config/i386/i386.c (override_options): Disable x87 fancy math * config/i386/i386.c (override_options): Disable x87 fancy math
......
...@@ -921,11 +921,16 @@ compute_flow_insensitive_aliasing (struct alias_info *ai) ...@@ -921,11 +921,16 @@ compute_flow_insensitive_aliasing (struct alias_info *ai)
/* Skip memory tags and variables that have never been /* Skip memory tags and variables that have never been
written to. We also need to check if the variables are written to. We also need to check if the variables are
call-clobbered because they may be overwritten by call-clobbered because they may be overwritten by
function calls. */ function calls.
tag_stored_p = bitmap_bit_p (ai->written_vars, tag_ann->uid)
|| is_call_clobbered (tag); Note this is effectively random accessing elements in
var_stored_p = bitmap_bit_p (ai->written_vars, v_ann->uid) the sparse bitset, which can be highly inefficient.
|| is_call_clobbered (var); So we first check the call_clobbered status of the
tag and variable before querying the bitmap. */
tag_stored_p = is_call_clobbered (tag)
|| bitmap_bit_p (ai->written_vars, tag_ann->uid);
var_stored_p = is_call_clobbered (var)
|| bitmap_bit_p (ai->written_vars, v_ann->uid);
if (!tag_stored_p && !var_stored_p) if (!tag_stored_p && !var_stored_p)
continue; continue;
......
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