aboutsummaryrefslogtreecommitdiff
path: root/gcc/gimple-range-path.cc
diff options
context:
space:
mode:
authorAndrew MacLeod <amacleod@redhat.com>2024-05-17 10:18:39 -0400
committerAndrew MacLeod <amacleod@redhat.com>2024-05-23 16:47:17 -0400
commitfca649dedaf6c4025ae3471cc1f322a90ebdd19a (patch)
tree5b3dfbebaf53a99783f595aab0426bf0b53820c7 /gcc/gimple-range-path.cc
parent3be530f6d77ec24c94589341b069b199cfe6c2eb (diff)
downloadgcc-fca649dedaf6c4025ae3471cc1f322a90ebdd19a.zip
gcc-fca649dedaf6c4025ae3471cc1f322a90ebdd19a.tar.gz
gcc-fca649dedaf6c4025ae3471cc1f322a90ebdd19a.tar.bz2
Rename relation oracle and API.
With more oracles incoming, rename the range_query oracle () method to relation (), and remove the redundant 'relation' text from register and query methods, resulting in calls that look like: relation ()->record (...) and relation ()->query (...) * gimple-range-cache.cc (ranger_cache::dump_bb): Use m_relation. (ranger_cache::fill_block_cache): Likewise * gimple-range-fold.cc (fur_stmt::get_phi_operand): Use new names. (fur_depend::register_relation): Likewise. (fold_using_range::range_of_phi): Likewise. * gimple-range-path.cc (path_range_query::path_range_query): Likewise. (path_range_query::~path_range_query): Likewise. (ath_range_query::compute_ranges): Likewise. (jt_fur_source::register_relation): Likewise. (jt_fur_source::query_relation): Likewise. (path_range_query::maybe_register_phi_relation): Likewise. * gimple-range-path.h (get_path_oracle): Likewise. * gimple-range.cc (gimple_ranger::gimple_ranger): Likewise. (gimple_ranger::~gimple_ranger): Likewise. * value-query.cc (range_query::create_relation_oracle): Likewise. (range_query::destroy_relation_oracle): Likewise. (range_query::share_oracles): Likewise. (range_query::range_query): Likewise. * value-query.h (value_query::relation): Rename from oracle. (m_relation): Rename from m_oracle. * value-relation.cc (relation_oracle::query): Rename from query_relation. (equiv_oracle::query): Likewise. (equiv_oracle::record): Rename from register_relation. (relation_oracle::record): Likewise. (dom_oracle::record): Likewise. (dom_oracle::query): Rename from query_relation. (path_oracle::record): Rename from register_relation. (path_oracle::query): Rename from query_relation. * value-relation.h (*::record): Rename from register_relation. (*::query): Rename from query_relation.
Diffstat (limited to 'gcc/gimple-range-path.cc')
-rw-r--r--gcc/gimple-range-path.cc18
1 files changed, 9 insertions, 9 deletions
diff --git a/gcc/gimple-range-path.cc b/gcc/gimple-range-path.cc
index cf7e040..e35bec0 100644
--- a/gcc/gimple-range-path.cc
+++ b/gcc/gimple-range-path.cc
@@ -44,7 +44,7 @@ path_range_query::path_range_query (gimple_ranger &ranger,
m_ranger (ranger),
m_resolve (resolve)
{
- m_oracle = new path_oracle (&(m_ranger.oracle ()));
+ m_relation = new path_oracle (&(m_ranger.relation ()));
reset_path (path, dependencies);
}
@@ -54,13 +54,13 @@ path_range_query::path_range_query (gimple_ranger &ranger, bool resolve)
m_ranger (ranger),
m_resolve (resolve)
{
- m_oracle = new path_oracle (&(m_ranger.oracle ()));
+ m_relation = new path_oracle (&(m_ranger.relation ()));
}
path_range_query::~path_range_query ()
{
- delete m_oracle;
- m_oracle = NULL;
+ delete m_relation;
+ m_relation = NULL;
}
// Return TRUE if NAME is an exit dependency for the path.
@@ -563,7 +563,7 @@ path_range_query::compute_ranges (const bitmap_head *dependencies)
if (m_resolve)
{
path_oracle *p = get_path_oracle ();
- p->reset_path (&(m_ranger.oracle ()));
+ p->reset_path (&(m_ranger.relation ()));
}
if (DEBUG_SOLVER)
@@ -636,7 +636,7 @@ jt_fur_source::jt_fur_source (gimple *s,
void
jt_fur_source::register_relation (gimple *, relation_kind k, tree op1, tree op2)
{
- m_query->oracle ().register_relation (m_entry, k, op1, op2);
+ m_query->relation ().record (m_entry, k, op1, op2);
}
// Ignore edge and register relation on entry to path.
@@ -644,7 +644,7 @@ jt_fur_source::register_relation (gimple *, relation_kind k, tree op1, tree op2)
void
jt_fur_source::register_relation (edge, relation_kind k, tree op1, tree op2)
{
- m_query->oracle ().register_relation (m_entry, k, op1, op2);
+ m_query->relation ().record (m_entry, k, op1, op2);
}
relation_kind
@@ -653,7 +653,7 @@ jt_fur_source::query_relation (tree op1, tree op2)
if (TREE_CODE (op1) != SSA_NAME || TREE_CODE (op2) != SSA_NAME)
return VREL_VARYING;
- return m_query->oracle().query_relation (m_entry, op1, op2);
+ return m_query->relation ().query (m_entry, op1, op2);
}
// Return the range of STMT at the end of the path being analyzed.
@@ -707,7 +707,7 @@ path_range_query::maybe_register_phi_relation (gphi *phi, edge e)
fprintf (dump_file, "maybe_register_phi_relation in bb%d:", bb->index);
get_path_oracle ()->killing_def (result);
- m_oracle->register_relation (entry_bb (), VREL_EQ, arg, result);
+ m_relation->record (entry_bb (), VREL_EQ, arg, result);
}
// Compute relations for each PHI in BB. For example: