aboutsummaryrefslogtreecommitdiff
path: root/gcc/value-query.h
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/value-query.h')
-rw-r--r--gcc/value-query.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/gcc/value-query.h b/gcc/value-query.h
index 54af031..5161d23 100644
--- a/gcc/value-query.h
+++ b/gcc/value-query.h
@@ -22,6 +22,8 @@ along with GCC; see the file COPYING3. If not see
#ifndef GCC_QUERY_H
#define GCC_QUERY_H
+#include "value-relation.h"
+
// The value_query class is used by optimization passes that require
// valueizing SSA names in terms of a tree value, but have no neeed
// for ranges.
@@ -91,6 +93,14 @@ public:
virtual bool range_on_edge (irange &r, edge, tree expr);
virtual bool range_of_stmt (irange &r, gimple *, tree name = NULL);
+ // Query if there is any relation between SSA1 and SSA2.
+ relation_kind query_relation (gimple *s, tree ssa1, tree ssa2,
+ bool get_range = true);
+ relation_kind query_relation (edge e, tree ssa1, tree ssa2,
+ bool get_range = true);
+ // If present, Access relation oracle for more advanced uses.
+ inline relation_oracle *oracle () const { return m_oracle; }
+
// DEPRECATED: This method is used from vr-values. The plan is to
// rewrite all uses of it to the above API.
virtual const class value_range_equiv *get_value_range (const_tree,
@@ -102,6 +112,7 @@ protected:
void free_value_range_equiv (class value_range_equiv *);
bool get_tree_range (irange &r, tree expr, gimple *stmt);
bool get_arith_expr_range (irange &r, tree expr, gimple *stmt);
+ relation_oracle *m_oracle;
private:
class equiv_allocator *equiv_alloc;