summaryrefslogtreecommitdiff
path: root/gcc/tree-ssa-scopedtables.h
diff options
context:
space:
mode:
authorlaw <law@138bc75d-0d04-0410-961f-82ee72b054a4>2015-09-11 21:32:38 +0000
committerlaw <law@138bc75d-0d04-0410-961f-82ee72b054a4>2015-09-11 21:32:38 +0000
commit01e5628590060cf4b472f105ff1095498a1c573b (patch)
treed8af52df36b4b2862fdcabe01a633ddf05f1a06f /gcc/tree-ssa-scopedtables.h
parentd3e2cde20a99bcb6bdb5a7655cd27b0950815115 (diff)
downloadgcc-01e5628590060cf4b472f105ff1095498a1c573b.tar.gz
[PATCH] Another small cleanup to the const_and_copies stack
2015-09-11 Jeff Law <law@redhat.com> PR tree-optimization/47679 * tree-ssa-dom.c (struct cond_equivalence): Update comment. * tree-ssa-scopedtables.h (class const_and_copies): Prefix data member with m_. Update inline member functions as necessary. Add toplevel comment. * tree-ssa-scopedtables.c: Update const_and_copies's member functions to use m_ prefix to access the stack. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@227697 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/tree-ssa-scopedtables.h')
-rw-r--r--gcc/tree-ssa-scopedtables.h14
1 files changed, 10 insertions, 4 deletions
diff --git a/gcc/tree-ssa-scopedtables.h b/gcc/tree-ssa-scopedtables.h
index 13f7ccb180e..f7d9ca4320c 100644
--- a/gcc/tree-ssa-scopedtables.h
+++ b/gcc/tree-ssa-scopedtables.h
@@ -20,14 +20,20 @@ along with GCC; see the file COPYING3. If not see
#ifndef GCC_TREE_SSA_SCOPED_TABLES_H
#define GCC_TREE_SSA_SCOPED_TABLES_H
+/* This class defines an unwindable const/copy equivalence table
+ layered on top of SSA_NAME_VALUE/set_ssa_name_value.
+
+ Essentially it's just a stack of name,prev value pairs with a
+ special marker (NULL) to indicate unwind points. */
+
class const_and_copies
{
public:
- const_and_copies (void) { stack.create (20); };
- ~const_and_copies (void) { stack.release (); }
+ const_and_copies (void) { m_stack.create (20); };
+ ~const_and_copies (void) { m_stack.release (); }
/* Push the unwinding marker onto the stack. */
- void push_marker (void) { stack.safe_push (NULL_TREE); }
+ void push_marker (void) { m_stack.safe_push (NULL_TREE); }
/* Restore the const/copies table to its state when the last marker
was pushed. */
@@ -47,7 +53,7 @@ class const_and_copies
void invalidate (tree);
private:
- vec<tree> stack;
+ vec<tree> m_stack;
};
#endif /* GCC_TREE_SSA_SCOPED_TABLES_H */