Title: [147299] branches/dfgFourthTier/Source/_javascript_Core
Revision
147299
Author
[email protected]
Date
2013-03-31 21:33:40 -0700 (Sun, 31 Mar 2013)

Log Message

https://bugs.webkit.org/show_bug.cgi?id=113656
Fix Sam's nits.

Unreviewed.

* ftl/FTLAbstractHeap.cpp:
(JSC::FTL::IndexedAbstractHeap::initialize):
* ftl/FTLAbstractHeap.h:
(IndexedAbstractHeap):
(AbsoluteAbstractHeap):
* ftl/FTLAbstractHeapRepository.h:
(AbstractHeapRepository):

Modified Paths

Diff

Modified: branches/dfgFourthTier/Source/_javascript_Core/ChangeLog (147298 => 147299)


--- branches/dfgFourthTier/Source/_javascript_Core/ChangeLog	2013-04-01 04:29:51 UTC (rev 147298)
+++ branches/dfgFourthTier/Source/_javascript_Core/ChangeLog	2013-04-01 04:33:40 UTC (rev 147299)
@@ -1,5 +1,20 @@
 2013-03-31  Filip Pizlo  <[email protected]>
 
+        https://bugs.webkit.org/show_bug.cgi?id=113656
+        Fix Sam's nits.
+
+        Unreviewed.
+
+        * ftl/FTLAbstractHeap.cpp:
+        (JSC::FTL::IndexedAbstractHeap::initialize):
+        * ftl/FTLAbstractHeap.h:
+        (IndexedAbstractHeap):
+        (AbsoluteAbstractHeap):
+        * ftl/FTLAbstractHeapRepository.h:
+        (AbstractHeapRepository):
+
+2013-03-31  Filip Pizlo  <[email protected]>
+
         fourthTier: FTL JIT should support GetByVal on Int32 arrays
         https://bugs.webkit.org/show_bug.cgi?id=113668
 

Modified: branches/dfgFourthTier/Source/_javascript_Core/ftl/FTLAbstractHeap.cpp (147298 => 147299)


--- branches/dfgFourthTier/Source/_javascript_Core/ftl/FTLAbstractHeap.cpp	2013-04-01 04:29:51 UTC (rev 147298)
+++ branches/dfgFourthTier/Source/_javascript_Core/ftl/FTLAbstractHeap.cpp	2013-04-01 04:33:40 UTC (rev 147299)
@@ -146,9 +146,7 @@
     }
     
     for (unsigned power = 4; power <= sizeof(void*) * 8; power += 4) {
-        // The crazy way of testing of index >= 2 ** power
-        // (where I use ** to denote pow()).
-        if ((index >> 1) >> (power - 1))
+        if (isGreaterThanNonZeroPowerOfTwo(index, power))
             continue;
         
         unsigned numHexlets = power >> 2;
@@ -165,7 +163,7 @@
         
         size_t accumulator = index;
         for (unsigned i = 0; i < numHexlets; ++i) {
-            characters[stringLength - i - 1] = ("0123456789ABCDEF")[accumulator & 0xF];
+            characters[stringLength - i - 1] = lowerNibbleToASCIIHexDigit(accumulator);
             accumulator >>= 4;
         }
         

Modified: branches/dfgFourthTier/Source/_javascript_Core/ftl/FTLAbstractHeap.h (147298 => 147299)


--- branches/dfgFourthTier/Source/_javascript_Core/ftl/FTLAbstractHeap.h	2013-04-01 04:29:51 UTC (rev 147298)
+++ branches/dfgFourthTier/Source/_javascript_Core/ftl/FTLAbstractHeap.h	2013-04-01 04:33:40 UTC (rev 147299)
@@ -173,11 +173,12 @@
     bool m_canShift;
     FixedArray<AbstractField, 16> m_smallIndices;
     
-    struct MyHashTraits : WTF::GenericHashTraits<ptrdiff_t> {
+    struct WithoutZeroOrOneHashTraits : WTF::GenericHashTraits<ptrdiff_t> {
         static void constructDeletedValue(ptrdiff_t& slot) { slot = 1; }
         static bool isDeletedValue(ptrdiff_t value) { return value == 1; }
     };
-    typedef HashMap<ptrdiff_t, OwnPtr<AbstractField>, WTF::IntHash<ptrdiff_t>, MyHashTraits> MapType;
+    typedef HashMap<ptrdiff_t, OwnPtr<AbstractField>, WTF::IntHash<ptrdiff_t>, WithoutZeroOrOneHashTraits> MapType;
+    
     OwnPtr<MapType> m_largeIndices;
     Vector<CString, 16> m_largeIndexNames;
 };
@@ -219,7 +220,6 @@
     const AbstractHeap& operator[](void* address) { return at(address); }
 
 private:
-    
     // The trick here is that the indexed heap is "indexed" by a pointer-width
     // integer. Pointers are themselves pointer-width integers. So we can reuse
     // all of the functionality.

Modified: branches/dfgFourthTier/Source/_javascript_Core/ftl/FTLAbstractHeapRepository.h (147298 => 147299)


--- branches/dfgFourthTier/Source/_javascript_Core/ftl/FTLAbstractHeapRepository.h	2013-04-01 04:29:51 UTC (rev 147298)
+++ branches/dfgFourthTier/Source/_javascript_Core/ftl/FTLAbstractHeapRepository.h	2013-04-01 04:33:40 UTC (rev 147299)
@@ -91,7 +91,6 @@
     friend class AbstractHeap;
     
     unsigned m_tbaaKind;
-    
 };
 
 } } // namespace JSC::FTL
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to