Bug 1029830 - IonMonkey: GVN: Rename "insert" to "add" for consistency with the HashSet API r=nbp
authorDan Gohman <sunfish@mozilla.com>
Wed, 17 Sep 2014 10:27:24 -0700
changeset 205881 2079c454f90817279f650f251512638c1c28dfc1
parent 205880 6e1ce34f558a14b17ba3321401970ea40152db37
child 205882 f212bee81c3ce73390ec63c0e6ee02ef9e41f522
push id27507
push userryanvm@gmail.com
push dateThu, 18 Sep 2014 02:16:54 +0000
treeherdermozilla-central@488d490da742 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersnbp
bugs1029830
milestone35.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1029830 - IonMonkey: GVN: Rename "insert" to "add" for consistency with the HashSet API r=nbp
js/src/jit/ValueNumbering.cpp
js/src/jit/ValueNumbering.h
--- a/js/src/jit/ValueNumbering.cpp
+++ b/js/src/jit/ValueNumbering.cpp
@@ -88,17 +88,17 @@ ValueNumberer::VisibleValues::findLeader
 ValueNumberer::VisibleValues::AddPtr
 ValueNumberer::VisibleValues::findLeaderForAdd(MDefinition *def)
 {
     return set_.lookupForAdd(def);
 }
 
 // Insert a value into the set.
 bool
-ValueNumberer::VisibleValues::insert(AddPtr p, MDefinition *def)
+ValueNumberer::VisibleValues::add(AddPtr p, MDefinition *def)
 {
     return set_.add(p, def);
 }
 
 // Insert a value onto the set overwriting any existing entry.
 void
 ValueNumberer::VisibleValues::overwrite(AddPtr p, MDefinition *def)
 {
@@ -416,17 +416,17 @@ ValueNumberer::leader(MDefinition *def)
                 return rep;
             }
 
             // The congruent value doesn't dominate. It never will again in this
             // dominator tree, so overwrite it.
             values_.overwrite(p, def);
         } else {
             // No match. Add a new entry.
-            if (!values_.insert(p, def))
+            if (!values_.add(p, def))
                 return nullptr;
         }
     }
 
     return def;
 }
 
 // Test whether the given phi is dominated by a congruent phi.
--- a/js/src/jit/ValueNumbering.h
+++ b/js/src/jit/ValueNumbering.h
@@ -43,17 +43,17 @@ class ValueNumberer
         explicit VisibleValues(TempAllocator &alloc);
         bool init();
 
         typedef ValueSet::Ptr Ptr;
         typedef ValueSet::AddPtr AddPtr;
 
         Ptr findLeader(const MDefinition *def) const;
         AddPtr findLeaderForAdd(MDefinition *def);
-        bool insert(AddPtr p, MDefinition *def);
+        bool add(AddPtr p, MDefinition *def);
         void overwrite(AddPtr p, MDefinition *def);
         void forget(const MDefinition *def);
         void clear();
 #ifdef DEBUG
         bool has(const MDefinition *def) const;
 #endif
     };