<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[167546] trunk/Source/bmalloc</title>
</head>
<body>
<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; }
#msg dl a { font-weight: bold}
#msg dl a:link { color:#fc3; }
#msg dl a:active { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/167546">167546</a></dd>
<dt>Author</dt> <dd>ggaren@apple.com</dd>
<dt>Date</dt> <dd>2014-04-19 13:41:16 -0700 (Sat, 19 Apr 2014)</dd>
</dl>
<h3>Log Message</h3>
<pre>2014-04-19 Geoffrey Garen <ggaren@apple.com>
Rolled out <a href="http://trac.webkit.org/projects/webkit/changeset/167502">r167502</a> because it caused a crash on the facebook benchmark.
Unreviewed.
bmalloc: Added an XSmall line size
https://bugs.webkit.org/show_bug.cgi?id=131851
Reviewed by Sam Weinig.</pre>
<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkSourcebmallocChangeLog">trunk/Source/bmalloc/ChangeLog</a></li>
<li><a href="#trunkSourcebmallocbmallocAllocatorcpp">trunk/Source/bmalloc/bmalloc/Allocator.cpp</a></li>
<li><a href="#trunkSourcebmallocbmallocAllocatorh">trunk/Source/bmalloc/bmalloc/Allocator.h</a></li>
<li><a href="#trunkSourcebmallocbmallocChunkh">trunk/Source/bmalloc/bmalloc/Chunk.h</a></li>
<li><a href="#trunkSourcebmallocbmallocDeallocatorcpp">trunk/Source/bmalloc/bmalloc/Deallocator.cpp</a></li>
<li><a href="#trunkSourcebmallocbmallocDeallocatorh">trunk/Source/bmalloc/bmalloc/Deallocator.h</a></li>
<li><a href="#trunkSourcebmallocbmallocHeapcpp">trunk/Source/bmalloc/bmalloc/Heap.cpp</a></li>
<li><a href="#trunkSourcebmallocbmallocHeaph">trunk/Source/bmalloc/bmalloc/Heap.h</a></li>
<li><a href="#trunkSourcebmallocbmallocLargeChunkh">trunk/Source/bmalloc/bmalloc/LargeChunk.h</a></li>
<li><a href="#trunkSourcebmallocbmallocLineh">trunk/Source/bmalloc/bmalloc/Line.h</a></li>
<li><a href="#trunkSourcebmallocbmallocMediumAllocatorh">trunk/Source/bmalloc/bmalloc/MediumAllocator.h</a></li>
<li><a href="#trunkSourcebmallocbmallocObjectTypecpp">trunk/Source/bmalloc/bmalloc/ObjectType.cpp</a></li>
<li><a href="#trunkSourcebmallocbmallocObjectTypeh">trunk/Source/bmalloc/bmalloc/ObjectType.h</a></li>
<li><a href="#trunkSourcebmallocbmallocSegregatedFreeListh">trunk/Source/bmalloc/bmalloc/SegregatedFreeList.h</a></li>
<li><a href="#trunkSourcebmallocbmallocSizesh">trunk/Source/bmalloc/bmalloc/Sizes.h</a></li>
<li><a href="#trunkSourcebmallocbmallocSmallAllocatorh">trunk/Source/bmalloc/bmalloc/SmallAllocator.h</a></li>
<li><a href="#trunkSourcebmallocbmallocSmallTraitsh">trunk/Source/bmalloc/bmalloc/SmallTraits.h</a></li>
<li><a href="#trunkSourcebmallocbmallocVMHeapcpp">trunk/Source/bmalloc/bmalloc/VMHeap.cpp</a></li>
<li><a href="#trunkSourcebmallocbmallocVMHeaph">trunk/Source/bmalloc/bmalloc/VMHeap.h</a></li>
<li><a href="#trunkSourcebmallocbmallocbmalloch">trunk/Source/bmalloc/bmalloc/bmalloc.h</a></li>
<li><a href="#trunkSourcebmallocbmallocxcodeprojprojectpbxproj">trunk/Source/bmalloc/bmalloc.xcodeproj/project.pbxproj</a></li>
</ul>
<h3>Removed Paths</h3>
<ul>
<li><a href="#trunkSourcebmallocbmallocXSmallAllocatorh">trunk/Source/bmalloc/bmalloc/XSmallAllocator.h</a></li>
<li><a href="#trunkSourcebmallocbmallocXSmallChunkh">trunk/Source/bmalloc/bmalloc/XSmallChunk.h</a></li>
<li><a href="#trunkSourcebmallocbmallocXSmallLineh">trunk/Source/bmalloc/bmalloc/XSmallLine.h</a></li>
<li><a href="#trunkSourcebmallocbmallocXSmallPageh">trunk/Source/bmalloc/bmalloc/XSmallPage.h</a></li>
<li><a href="#trunkSourcebmallocbmallocXSmallTraitsh">trunk/Source/bmalloc/bmalloc/XSmallTraits.h</a></li>
</ul>
</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkSourcebmallocChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/bmalloc/ChangeLog (167545 => 167546)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/bmalloc/ChangeLog        2014-04-19 20:40:39 UTC (rev 167545)
+++ trunk/Source/bmalloc/ChangeLog        2014-04-19 20:41:16 UTC (rev 167546)
</span><span class="lines">@@ -1,5 +1,16 @@
</span><span class="cx"> 2014-04-19 Geoffrey Garen <ggaren@apple.com>
</span><span class="cx">
</span><ins>+ Rolled out r167502 because it caused a crash on the facebook benchmark.
+
+ Unreviewed.
+
+ bmalloc: Added an XSmall line size
+ https://bugs.webkit.org/show_bug.cgi?id=131851
+
+ Reviewed by Sam Weinig.
+
+2014-04-19 Geoffrey Garen <ggaren@apple.com>
+
</ins><span class="cx"> bmalloc: Mutex should be harder to use wrong
</span><span class="cx"> https://bugs.webkit.org/show_bug.cgi?id=131879
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourcebmallocbmallocAllocatorcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/bmalloc/bmalloc/Allocator.cpp (167545 => 167546)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/bmalloc/bmalloc/Allocator.cpp        2014-04-19 20:40:39 UTC (rev 167545)
+++ trunk/Source/bmalloc/bmalloc/Allocator.cpp        2014-04-19 20:41:16 UTC (rev 167546)
</span><span class="lines">@@ -43,11 +43,10 @@
</span><span class="cx"> , m_mediumAllocatorLog()
</span><span class="cx"> {
</span><span class="cx"> unsigned short size = alignment;
</span><del>- for ( ; size <= xSmallMax; size += alignment)
- xSmallAllocatorFor(size) = XSmallAllocator(size);
-
- for ( ; size <= smallMax; size += alignment)
- smallAllocatorFor(size) = SmallAllocator(size);
</del><ins>+ for (auto& allocator : m_smallAllocators) {
+ allocator = SmallAllocator(size);
+ size += alignment;
+ }
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> Allocator::~Allocator()
</span><span class="lines">@@ -57,10 +56,6 @@
</span><span class="cx">
</span><span class="cx"> void Allocator::scavenge()
</span><span class="cx"> {
</span><del>- for (auto& allocator : m_xSmallAllocators)
- log(allocator);
- processXSmallAllocatorLog();
-
</del><span class="cx"> for (auto& allocator : m_smallAllocators)
</span><span class="cx"> log(allocator);
</span><span class="cx"> processSmallAllocatorLog();
</span><span class="lines">@@ -69,37 +64,14 @@
</span><span class="cx"> processMediumAllocatorLog();
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void Allocator::log(XSmallAllocator& allocator)
-{
- if (allocator.isNull())
- return;
-
- if (m_xSmallAllocatorLog.size() == m_xSmallAllocatorLog.capacity())
- processXSmallAllocatorLog();
-
- m_xSmallAllocatorLog.push(std::make_pair(allocator.line(), allocator.derefCount()));
-}
-
-void Allocator::processXSmallAllocatorLog()
-{
- std::lock_guard<StaticMutex> lock(PerProcess<Heap>::mutex());
-
- for (auto& logEntry : m_xSmallAllocatorLog) {
- if (!logEntry.first->deref(lock, logEntry.second))
- continue;
- m_deallocator.deallocateXSmallLine(lock, logEntry.first);
- }
- m_xSmallAllocatorLog.clear();
-}
-
</del><span class="cx"> void Allocator::log(SmallAllocator& allocator)
</span><span class="cx"> {
</span><del>- if (allocator.isNull())
- return;
-
</del><span class="cx"> if (m_smallAllocatorLog.size() == m_smallAllocatorLog.capacity())
</span><span class="cx"> processSmallAllocatorLog();
</span><span class="cx">
</span><ins>+ if (allocator.isNull())
+ return;
+
</ins><span class="cx"> m_smallAllocatorLog.push(std::make_pair(allocator.line(), allocator.derefCount()));
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -117,12 +89,12 @@
</span><span class="cx">
</span><span class="cx"> void Allocator::log(MediumAllocator& allocator)
</span><span class="cx"> {
</span><del>- if (allocator.isNull())
- return;
-
</del><span class="cx"> if (m_mediumAllocatorLog.size() == m_mediumAllocatorLog.capacity())
</span><span class="cx"> processMediumAllocatorLog();
</span><span class="cx">
</span><ins>+ if (allocator.isNull())
+ return;
+
</ins><span class="cx"> m_mediumAllocatorLog.push(std::make_pair(allocator.line(), allocator.derefCount()));
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -172,13 +144,6 @@
</span><span class="cx"> void* dummy;
</span><span class="cx"> BASSERT(!allocateFastCase(size, dummy));
</span><span class="cx"> )
</span><del>- if (size <= xSmallMax) {
- XSmallAllocator& allocator = xSmallAllocatorFor(size);
- log(allocator);
- allocator.refill(m_deallocator.allocateXSmallLine());
- return allocator.allocate();
- }
-
</del><span class="cx"> if (size <= smallMax) {
</span><span class="cx"> SmallAllocator& allocator = smallAllocatorFor(size);
</span><span class="cx"> log(allocator);
</span></span></pre></div>
<a id="trunkSourcebmallocbmallocAllocatorh"></a>
<div class="modfile"><h4>Modified: trunk/Source/bmalloc/bmalloc/Allocator.h (167545 => 167546)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/bmalloc/bmalloc/Allocator.h        2014-04-19 20:40:39 UTC (rev 167545)
+++ trunk/Source/bmalloc/bmalloc/Allocator.h        2014-04-19 20:41:16 UTC (rev 167546)
</span><span class="lines">@@ -30,7 +30,6 @@
</span><span class="cx"> #include "MediumAllocator.h"
</span><span class="cx"> #include "Sizes.h"
</span><span class="cx"> #include "SmallAllocator.h"
</span><del>-#include "XSmallAllocator.h"
</del><span class="cx"> #include <array>
</span><span class="cx">
</span><span class="cx"> namespace bmalloc {
</span><span class="lines">@@ -51,40 +50,28 @@
</span><span class="cx"> void scavenge();
</span><span class="cx">
</span><span class="cx"> private:
</span><del>- XSmallAllocator& xSmallAllocatorFor(size_t);
</del><span class="cx"> SmallAllocator& smallAllocatorFor(size_t);
</span><del>-
</del><span class="cx"> void* allocateFastCase(SmallAllocator&);
</span><span class="cx">
</span><span class="cx"> void* allocateMedium(size_t);
</span><span class="cx"> void* allocateLarge(size_t);
</span><span class="cx"> void* allocateXLarge(size_t);
</span><span class="cx">
</span><del>- void log(XSmallAllocator&);
</del><span class="cx"> void log(SmallAllocator&);
</span><span class="cx"> void log(MediumAllocator&);
</span><span class="cx">
</span><del>- void processXSmallAllocatorLog();
</del><span class="cx"> void processSmallAllocatorLog();
</span><span class="cx"> void processMediumAllocatorLog();
</span><span class="cx">
</span><span class="cx"> Deallocator& m_deallocator;
</span><span class="cx">
</span><del>- std::array<XSmallAllocator, xSmallMax / alignment> m_xSmallAllocators;
</del><span class="cx"> std::array<SmallAllocator, smallMax / alignment> m_smallAllocators;
</span><span class="cx"> MediumAllocator m_mediumAllocator;
</span><span class="cx">
</span><del>- FixedVector<std::pair<XSmallLine*, unsigned char>, xSmallAllocatorLogCapacity> m_xSmallAllocatorLog;
</del><span class="cx"> FixedVector<std::pair<SmallLine*, unsigned char>, smallAllocatorLogCapacity> m_smallAllocatorLog;
</span><span class="cx"> FixedVector<std::pair<MediumLine*, unsigned char>, mediumAllocatorLogCapacity> m_mediumAllocatorLog;
</span><span class="cx"> };
</span><span class="cx">
</span><del>-inline XSmallAllocator& Allocator::xSmallAllocatorFor(size_t size)
-{
- size_t index = mask((size - 1ul) / alignment, m_xSmallAllocators.size() - 1);
- return m_xSmallAllocators[index];
-}
-
</del><span class="cx"> inline SmallAllocator& Allocator::smallAllocatorFor(size_t size)
</span><span class="cx"> {
</span><span class="cx"> size_t index = mask((size - 1ul) / alignment, m_smallAllocators.size() - 1);
</span><span class="lines">@@ -93,25 +80,15 @@
</span><span class="cx">
</span><span class="cx"> inline bool Allocator::allocateFastCase(size_t size, void*& object)
</span><span class="cx"> {
</span><del>- if (size <= xSmallMax) {
- XSmallAllocator& allocator = xSmallAllocatorFor(size);
- if (!allocator.canAllocate())
- return false;
-
- object = allocator.allocate();
- return true;
- }
-
- if (size <= smallMax) {
- SmallAllocator& allocator = smallAllocatorFor(size);
- if (!allocator.canAllocate())
- return false;
</del><ins>+ if (size > smallMax)
+ return false;
</ins><span class="cx">
</span><del>- object = allocator.allocate();
- return true;
- }
-
- return false;
</del><ins>+ SmallAllocator& allocator = smallAllocatorFor(size);
+ if (!allocator.canAllocate())
+ return false;
+
+ object = allocator.allocate();
+ return true;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> inline void* Allocator::allocate(size_t size)
</span></span></pre></div>
<a id="trunkSourcebmallocbmallocChunkh"></a>
<div class="modfile"><h4>Modified: trunk/Source/bmalloc/bmalloc/Chunk.h (167545 => 167546)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/bmalloc/bmalloc/Chunk.h        2014-04-19 20:40:39 UTC (rev 167545)
+++ trunk/Source/bmalloc/bmalloc/Chunk.h        2014-04-19 20:41:16 UTC (rev 167546)
</span><span class="lines">@@ -77,7 +77,7 @@
</span><span class="cx"> template<class Traits>
</span><span class="cx"> inline auto Chunk<Traits>::get(void* object) -> Chunk*
</span><span class="cx"> {
</span><del>- BASSERT(!isLarge(object));
</del><ins>+ BASSERT(isSmallOrMedium(object));
</ins><span class="cx"> return static_cast<Chunk*>(mask(object, chunkMask));
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourcebmallocbmallocDeallocatorcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/bmalloc/bmalloc/Deallocator.cpp (167545 => 167546)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/bmalloc/bmalloc/Deallocator.cpp        2014-04-19 20:40:39 UTC (rev 167545)
+++ trunk/Source/bmalloc/bmalloc/Deallocator.cpp        2014-04-19 20:41:16 UTC (rev 167546)
</span><span class="lines">@@ -31,7 +31,6 @@
</span><span class="cx"> #include "Inline.h"
</span><span class="cx"> #include "PerProcess.h"
</span><span class="cx"> #include "SmallChunk.h"
</span><del>-#include "XSmallChunk.h"
</del><span class="cx"> #include <algorithm>
</span><span class="cx"> #include <sys/mman.h>
</span><span class="cx">
</span><span class="lines">@@ -58,8 +57,6 @@
</span><span class="cx"> std::lock_guard<StaticMutex> lock(PerProcess<Heap>::mutex());
</span><span class="cx"> Heap* heap = PerProcess<Heap>::getFastCase();
</span><span class="cx">
</span><del>- while (m_xSmallLineCache.size())
- heap->deallocateXSmallLine(lock, m_xSmallLineCache.pop());
</del><span class="cx"> while (m_smallLineCache.size())
</span><span class="cx"> heap->deallocateSmallLine(lock, m_smallLineCache.pop());
</span><span class="cx"> while (m_mediumLineCache.size())
</span><span class="lines">@@ -83,18 +80,13 @@
</span><span class="cx"> std::lock_guard<StaticMutex> lock(PerProcess<Heap>::mutex());
</span><span class="cx">
</span><span class="cx"> for (auto object : m_objectLog) {
</span><del>- if (isXSmall(object)) {
- XSmallLine* line = XSmallLine::get(object);
- if (!line->deref(lock))
- continue;
- deallocateXSmallLine(lock, line);
- } else if (isSmall(object)) {
</del><ins>+ if (isSmall(object)) {
</ins><span class="cx"> SmallLine* line = SmallLine::get(object);
</span><span class="cx"> if (!line->deref(lock))
</span><span class="cx"> continue;
</span><span class="cx"> deallocateSmallLine(lock, line);
</span><span class="cx"> } else {
</span><del>- BASSERT(isMedium(object));
</del><ins>+ BASSERT(isSmallOrMedium(object));
</ins><span class="cx"> MediumLine* line = MediumLine::get(object);
</span><span class="cx"> if (!line->deref(lock))
</span><span class="cx"> continue;
</span><span class="lines">@@ -112,7 +104,7 @@
</span><span class="cx"> if (!object)
</span><span class="cx"> return;
</span><span class="cx">
</span><del>- if (!isLarge(object)) {
</del><ins>+ if (isSmallOrMedium(object)) {
</ins><span class="cx"> processObjectLog();
</span><span class="cx"> m_objectLog.push(object);
</span><span class="cx"> return;
</span><span class="lines">@@ -133,14 +125,6 @@
</span><span class="cx"> m_smallLineCache.push(line);
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void Deallocator::deallocateXSmallLine(std::lock_guard<StaticMutex>& lock, XSmallLine* line)
-{
- if (m_xSmallLineCache.size() == m_xSmallLineCache.capacity())
- return PerProcess<Heap>::getFastCase()->deallocateXSmallLine(lock, line);
-
- m_xSmallLineCache.push(line);
-}
-
</del><span class="cx"> SmallLine* Deallocator::allocateSmallLine()
</span><span class="cx"> {
</span><span class="cx"> if (!m_smallLineCache.size()) {
</span><span class="lines">@@ -154,19 +138,6 @@
</span><span class="cx"> return m_smallLineCache.pop();
</span><span class="cx"> }
</span><span class="cx">
</span><del>-XSmallLine* Deallocator::allocateXSmallLine()
-{
- if (!m_xSmallLineCache.size()) {
- std::lock_guard<StaticMutex> lock(PerProcess<Heap>::mutex());
- Heap* heap = PerProcess<Heap>::getFastCase();
-
- while (m_xSmallLineCache.size() != m_xSmallLineCache.capacity())
- m_xSmallLineCache.push(heap->allocateXSmallLine(lock));
- }
-
- return m_xSmallLineCache.pop();
-}
-
</del><span class="cx"> void Deallocator::deallocateMediumLine(std::lock_guard<StaticMutex>& lock, MediumLine* line)
</span><span class="cx"> {
</span><span class="cx"> if (m_mediumLineCache.size() == m_mediumLineCache.capacity())
</span></span></pre></div>
<a id="trunkSourcebmallocbmallocDeallocatorh"></a>
<div class="modfile"><h4>Modified: trunk/Source/bmalloc/bmalloc/Deallocator.h (167545 => 167546)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/bmalloc/bmalloc/Deallocator.h        2014-04-19 20:40:39 UTC (rev 167545)
+++ trunk/Source/bmalloc/bmalloc/Deallocator.h        2014-04-19 20:41:16 UTC (rev 167546)
</span><span class="lines">@@ -30,7 +30,6 @@
</span><span class="cx"> #include "MediumLine.h"
</span><span class="cx"> #include "Sizes.h"
</span><span class="cx"> #include "SmallLine.h"
</span><del>-#include "XSmallLine.h"
</del><span class="cx">
</span><span class="cx"> namespace bmalloc {
</span><span class="cx">
</span><span class="lines">@@ -45,9 +44,6 @@
</span><span class="cx"> bool deallocateFastCase(void*);
</span><span class="cx"> void deallocateSlowCase(void*);
</span><span class="cx">
</span><del>- void deallocateXSmallLine(std::lock_guard<StaticMutex>&, XSmallLine*);
- XSmallLine* allocateXSmallLine();
-
</del><span class="cx"> void deallocateSmallLine(std::lock_guard<StaticMutex>&, SmallLine*);
</span><span class="cx"> SmallLine* allocateSmallLine();
</span><span class="cx">
</span><span class="lines">@@ -62,14 +58,13 @@
</span><span class="cx"> void processObjectLog();
</span><span class="cx">
</span><span class="cx"> FixedVector<void*, deallocatorLogCapacity> m_objectLog;
</span><del>- FixedVector<XSmallLine*, xSmallLineCacheCapacity> m_xSmallLineCache;
</del><span class="cx"> FixedVector<SmallLine*, smallLineCacheCapacity> m_smallLineCache;
</span><span class="cx"> FixedVector<MediumLine*, mediumLineCacheCapacity> m_mediumLineCache;
</span><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> inline bool Deallocator::deallocateFastCase(void* object)
</span><span class="cx"> {
</span><del>- if (isLarge(object))
</del><ins>+ if (!isSmallOrMedium(object))
</ins><span class="cx"> return false;
</span><span class="cx">
</span><span class="cx"> BASSERT(object);
</span></span></pre></div>
<a id="trunkSourcebmallocbmallocHeapcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/bmalloc/bmalloc/Heap.cpp (167545 => 167546)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/bmalloc/bmalloc/Heap.cpp        2014-04-19 20:40:39 UTC (rev 167545)
+++ trunk/Source/bmalloc/bmalloc/Heap.cpp        2014-04-19 20:41:16 UTC (rev 167546)
</span><span class="lines">@@ -32,7 +32,6 @@
</span><span class="cx"> #include "PerProcess.h"
</span><span class="cx"> #include "SmallChunk.h"
</span><span class="cx"> #include "XLargeChunk.h"
</span><del>-#include "XSmallChunk.h"
</del><span class="cx"> #include <thread>
</span><span class="cx">
</span><span class="cx"> namespace bmalloc {
</span><span class="lines">@@ -61,7 +60,6 @@
</span><span class="cx">
</span><span class="cx"> void Heap::scavenge(std::unique_lock<StaticMutex>& lock, std::chrono::milliseconds sleepDuration)
</span><span class="cx"> {
</span><del>- scavengeXSmallPages(lock, sleepDuration);
</del><span class="cx"> scavengeSmallPages(lock, sleepDuration);
</span><span class="cx"> scavengeMediumPages(lock, sleepDuration);
</span><span class="cx"> scavengeLargeRanges(lock, sleepDuration);
</span><span class="lines">@@ -85,22 +83,6 @@
</span><span class="cx"> }
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void Heap::scavengeXSmallPages(std::unique_lock<StaticMutex>& lock, std::chrono::milliseconds sleepDuration)
-{
- while (1) {
- if (m_isAllocatingPages) {
- m_isAllocatingPages = false;
-
- sleep(lock, sleepDuration);
- continue;
- }
-
- if (!m_xSmallPages.size())
- return;
- m_vmHeap.deallocateXSmallPage(lock, m_xSmallPages.pop());
- }
-}
-
</del><span class="cx"> void Heap::scavengeMediumPages(std::unique_lock<StaticMutex>& lock, std::chrono::milliseconds sleepDuration)
</span><span class="cx"> {
</span><span class="cx"> while (1) {
</span><span class="lines">@@ -134,27 +116,6 @@
</span><span class="cx"> }
</span><span class="cx"> }
</span><span class="cx">
</span><del>-XSmallLine* Heap::allocateXSmallLineSlowCase(std::lock_guard<StaticMutex>& lock)
-{
- m_isAllocatingPages = true;
-
- XSmallPage* page = [this]() {
- if (m_xSmallPages.size())
- return m_xSmallPages.pop();
-
- XSmallPage* page = m_vmHeap.allocateXSmallPage();
- vmAllocatePhysicalPages(page->begin()->begin(), vmPageSize);
- return page;
- }();
-
- XSmallLine* line = page->begin();
- for (auto it = line + 1; it != page->end(); ++it)
- m_xSmallLines.push(it);
-
- page->ref(lock);
- return line;
-}
-
</del><span class="cx"> SmallLine* Heap::allocateSmallLineSlowCase(std::lock_guard<StaticMutex>& lock)
</span><span class="cx"> {
</span><span class="cx"> m_isAllocatingPages = true;
</span></span></pre></div>
<a id="trunkSourcebmallocbmallocHeaph"></a>
<div class="modfile"><h4>Modified: trunk/Source/bmalloc/bmalloc/Heap.h (167545 => 167546)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/bmalloc/bmalloc/Heap.h        2014-04-19 20:40:39 UTC (rev 167545)
+++ trunk/Source/bmalloc/bmalloc/Heap.h        2014-04-19 20:41:16 UTC (rev 167546)
</span><span class="lines">@@ -28,12 +28,15 @@
</span><span class="cx">
</span><span class="cx"> #include "FixedVector.h"
</span><span class="cx"> #include "VMHeap.h"
</span><ins>+#include "MediumLine.h"
</ins><span class="cx"> #include "Mutex.h"
</span><ins>+#include "SmallPage.h"
</ins><span class="cx"> #include "MediumChunk.h"
</span><ins>+#include "MediumPage.h"
</ins><span class="cx"> #include "SegregatedFreeList.h"
</span><span class="cx"> #include "SmallChunk.h"
</span><ins>+#include "SmallLine.h"
</ins><span class="cx"> #include "Vector.h"
</span><del>-#include "XSmallChunk.h"
</del><span class="cx"> #include <array>
</span><span class="cx"> #include <mutex>
</span><span class="cx">
</span><span class="lines">@@ -45,9 +48,6 @@
</span><span class="cx"> class Heap {
</span><span class="cx"> public:
</span><span class="cx"> Heap(std::lock_guard<StaticMutex>&);
</span><del>-
- XSmallLine* allocateXSmallLine(std::lock_guard<StaticMutex>&);
- void deallocateXSmallLine(std::lock_guard<StaticMutex>&, XSmallLine*);
</del><span class="cx">
</span><span class="cx"> SmallLine* allocateSmallLine(std::lock_guard<StaticMutex>&);
</span><span class="cx"> void deallocateSmallLine(std::lock_guard<StaticMutex>&, SmallLine*);
</span><span class="lines">@@ -66,7 +66,6 @@
</span><span class="cx"> private:
</span><span class="cx"> ~Heap() = delete;
</span><span class="cx">
</span><del>- XSmallLine* allocateXSmallLineSlowCase(std::lock_guard<StaticMutex>&);
</del><span class="cx"> SmallLine* allocateSmallLineSlowCase(std::lock_guard<StaticMutex>&);
</span><span class="cx"> MediumLine* allocateMediumLineSlowCase(std::lock_guard<StaticMutex>&);
</span><span class="cx">
</span><span class="lines">@@ -79,16 +78,13 @@
</span><span class="cx"> void mergeLargeRight(EndTag*&, BeginTag*&, Range&, bool& hasPhysicalPages);
</span><span class="cx">
</span><span class="cx"> void concurrentScavenge();
</span><del>- void scavengeXSmallPages(std::unique_lock<StaticMutex>&, std::chrono::milliseconds);
</del><span class="cx"> void scavengeSmallPages(std::unique_lock<StaticMutex>&, std::chrono::milliseconds);
</span><span class="cx"> void scavengeMediumPages(std::unique_lock<StaticMutex>&, std::chrono::milliseconds);
</span><span class="cx"> void scavengeLargeRanges(std::unique_lock<StaticMutex>&, std::chrono::milliseconds);
</span><span class="cx">
</span><del>- Vector<XSmallLine*> m_xSmallLines;
</del><span class="cx"> Vector<SmallLine*> m_smallLines;
</span><span class="cx"> Vector<MediumLine*> m_mediumLines;
</span><span class="cx">
</span><del>- Vector<XSmallPage*> m_xSmallPages;
</del><span class="cx"> Vector<SmallPage*> m_smallPages;
</span><span class="cx"> Vector<MediumPage*> m_mediumPages;
</span><span class="cx">
</span><span class="lines">@@ -100,31 +96,6 @@
</span><span class="cx"> AsyncTask<Heap, decltype(&Heap::concurrentScavenge)> m_scavenger;
</span><span class="cx"> };
</span><span class="cx">
</span><del>-inline void Heap::deallocateXSmallLine(std::lock_guard<StaticMutex>& lock, XSmallLine* line)
-{
- XSmallPage* page = XSmallPage::get(line);
- if (page->deref(lock)) {
- m_xSmallPages.push(page);
- m_scavenger.run();
- return;
- }
- m_xSmallLines.push(line);
-}
-
-inline XSmallLine* Heap::allocateXSmallLine(std::lock_guard<StaticMutex>& lock)
-{
- while (m_xSmallLines.size()) {
- XSmallLine* line = m_xSmallLines.pop();
- XSmallPage* page = XSmallPage::get(line);
- if (!page->refCount(lock)) // The line was promoted to the small pages list.
- continue;
- page->ref(lock);
- return line;
- }
-
- return allocateXSmallLineSlowCase(lock);
-}
-
</del><span class="cx"> inline void Heap::deallocateSmallLine(std::lock_guard<StaticMutex>& lock, SmallLine* line)
</span><span class="cx"> {
</span><span class="cx"> SmallPage* page = SmallPage::get(line);
</span></span></pre></div>
<a id="trunkSourcebmallocbmallocLargeChunkh"></a>
<div class="modfile"><h4>Modified: trunk/Source/bmalloc/bmalloc/LargeChunk.h (167545 => 167546)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/bmalloc/bmalloc/LargeChunk.h        2014-04-19 20:40:39 UTC (rev 167545)
+++ trunk/Source/bmalloc/bmalloc/LargeChunk.h        2014-04-19 20:41:16 UTC (rev 167546)
</span><span class="lines">@@ -76,7 +76,7 @@
</span><span class="cx">
</span><span class="cx"> inline LargeChunk* LargeChunk::get(void* object)
</span><span class="cx"> {
</span><del>- BASSERT(isLarge(object));
</del><ins>+ BASSERT(!isSmallOrMedium(object));
</ins><span class="cx"> return static_cast<LargeChunk*>(mask(object, largeChunkMask));
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -89,7 +89,7 @@
</span><span class="cx">
</span><span class="cx"> inline EndTag* LargeChunk::endTag(void* object, size_t size)
</span><span class="cx"> {
</span><del>- BASSERT(isLarge(object));
</del><ins>+ BASSERT(!isSmallOrMedium(object));
</ins><span class="cx">
</span><span class="cx"> LargeChunk* chunk = get(object);
</span><span class="cx"> char* end = static_cast<char*>(object) + size;
</span></span></pre></div>
<a id="trunkSourcebmallocbmallocLineh"></a>
<div class="modfile"><h4>Modified: trunk/Source/bmalloc/bmalloc/Line.h (167545 => 167546)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/bmalloc/bmalloc/Line.h        2014-04-19 20:40:39 UTC (rev 167545)
+++ trunk/Source/bmalloc/bmalloc/Line.h        2014-04-19 20:41:16 UTC (rev 167546)
</span><span class="lines">@@ -58,7 +58,7 @@
</span><span class="cx"> template<class Traits>
</span><span class="cx"> inline auto Line<Traits>::get(void* object) -> Line*
</span><span class="cx"> {
</span><del>- BASSERT(!isLarge(object));
</del><ins>+ BASSERT(isSmallOrMedium(object));
</ins><span class="cx"> Chunk* chunk = Chunk::get(object);
</span><span class="cx"> size_t lineNumber = (reinterpret_cast<char*>(object) - reinterpret_cast<char*>(chunk)) / lineSize;
</span><span class="cx"> return &chunk->lines()[lineNumber];
</span></span></pre></div>
<a id="trunkSourcebmallocbmallocMediumAllocatorh"></a>
<div class="modfile"><h4>Modified: trunk/Source/bmalloc/bmalloc/MediumAllocator.h (167545 => 167546)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/bmalloc/bmalloc/MediumAllocator.h        2014-04-19 20:40:39 UTC (rev 167545)
+++ trunk/Source/bmalloc/bmalloc/MediumAllocator.h        2014-04-19 20:41:16 UTC (rev 167546)
</span><span class="lines">@@ -73,7 +73,7 @@
</span><span class="cx">
</span><span class="cx"> m_remaining -= size;
</span><span class="cx"> void* object = m_end - m_remaining - size;
</span><del>- BASSERT(objectType(object) == Medium);
</del><ins>+ BASSERT(isSmallOrMedium(object) && !isSmall(object));
</ins><span class="cx">
</span><span class="cx"> ++m_objectCount;
</span><span class="cx"> return object;
</span><span class="lines">@@ -99,7 +99,6 @@
</span><span class="cx"> m_end = line->end();
</span><span class="cx"> m_remaining = mediumLineSize;
</span><span class="cx"> m_objectCount = 0;
</span><del>- BASSERT(objectType(m_end - 1) == Medium);
</del><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> } // namespace bmalloc
</span></span></pre></div>
<a id="trunkSourcebmallocbmallocObjectTypecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/bmalloc/bmalloc/ObjectType.cpp (167545 => 167546)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/bmalloc/bmalloc/ObjectType.cpp        2014-04-19 20:40:39 UTC (rev 167545)
+++ trunk/Source/bmalloc/bmalloc/ObjectType.cpp        2014-04-19 20:41:16 UTC (rev 167546)
</span><span class="lines">@@ -30,27 +30,16 @@
</span><span class="cx">
</span><span class="cx"> ObjectType objectType(void* object)
</span><span class="cx"> {
</span><del>- switch (mask(reinterpret_cast<uintptr_t>(object), typeMask)) {
- case xSmallType: {
- return XSmall;
- }
- case smallType: {
- return Small;
- }
- case mediumType: {
</del><ins>+ if (isSmallOrMedium(object)) {
+ if (isSmall(object))
+ return Small;
</ins><span class="cx"> return Medium;
</span><span class="cx"> }
</span><del>- case largeType: {
- BeginTag* beginTag = LargeChunk::beginTag(object);
- if (!beginTag->isXLarge())
- return Large;
- return XLarge;
- }
- default: {
- RELEASE_BASSERT(false);
- return XLarge;
- }
- }
</del><ins>+
+ BeginTag* beginTag = LargeChunk::beginTag(object);
+ if (!beginTag->isXLarge())
+ return Large;
+ return XLarge;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> } // namespace bmalloc
</span></span></pre></div>
<a id="trunkSourcebmallocbmallocObjectTypeh"></a>
<div class="modfile"><h4>Modified: trunk/Source/bmalloc/bmalloc/ObjectType.h (167545 => 167546)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/bmalloc/bmalloc/ObjectType.h        2014-04-19 20:40:39 UTC (rev 167545)
+++ trunk/Source/bmalloc/bmalloc/ObjectType.h        2014-04-19 20:41:16 UTC (rev 167546)
</span><span class="lines">@@ -31,30 +31,21 @@
</span><span class="cx">
</span><span class="cx"> namespace bmalloc {
</span><span class="cx">
</span><del>-enum ObjectType { XSmall, Small, Medium, Large, XLarge };
</del><ins>+enum ObjectType { Small, Medium, Large, XLarge };
</ins><span class="cx">
</span><span class="cx"> ObjectType objectType(void*);
</span><span class="cx">
</span><del>-inline bool isXSmall(void* object)
</del><ins>+inline bool isSmallOrMedium(void* object)
</ins><span class="cx"> {
</span><del>- return mask(reinterpret_cast<uintptr_t>(object), typeMask) == xSmallType;
</del><ins>+ return test(object, smallOrMediumTypeMask);
</ins><span class="cx"> }
</span><span class="cx">
</span><del>-inline bool isSmall(void* object)
</del><ins>+inline bool isSmall(void* smallOrMedium)
</ins><span class="cx"> {
</span><del>- return mask(reinterpret_cast<uintptr_t>(object), typeMask) == smallType;
</del><ins>+ BASSERT(isSmallOrMedium(smallOrMedium));
+ return test(smallOrMedium, smallOrMediumSmallTypeMask);
</ins><span class="cx"> }
</span><span class="cx">
</span><del>-inline bool isMedium(void* object)
-{
- return mask(reinterpret_cast<uintptr_t>(object), typeMask) == mediumType;
-}
-
-inline bool isLarge(void* object)
-{
- return mask(reinterpret_cast<uintptr_t>(object), typeMask) == largeType;
-}
-
</del><span class="cx"> } // namespace bmalloc
</span><span class="cx">
</span><span class="cx"> #endif // ObjectType_h
</span></span></pre></div>
<a id="trunkSourcebmallocbmallocSegregatedFreeListh"></a>
<div class="modfile"><h4>Modified: trunk/Source/bmalloc/bmalloc/SegregatedFreeList.h (167545 => 167546)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/bmalloc/bmalloc/SegregatedFreeList.h        2014-04-19 20:40:39 UTC (rev 167545)
+++ trunk/Source/bmalloc/bmalloc/SegregatedFreeList.h        2014-04-19 20:41:16 UTC (rev 167546)
</span><span class="lines">@@ -58,7 +58,7 @@
</span><span class="cx"> Range take(List&, size_t);
</span><span class="cx"> Range takeGreedy(List&, size_t);
</span><span class="cx">
</span><del>- std::array<List, 18> m_lists;
</del><ins>+ std::array<List, 19> m_lists;
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> } // namespace bmalloc
</span></span></pre></div>
<a id="trunkSourcebmallocbmallocSizesh"></a>
<div class="modfile"><h4>Modified: trunk/Source/bmalloc/bmalloc/Sizes.h (167545 => 167546)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/bmalloc/bmalloc/Sizes.h        2014-04-19 20:40:39 UTC (rev 167545)
+++ trunk/Source/bmalloc/bmalloc/Sizes.h        2014-04-19 20:41:16 UTC (rev 167546)
</span><span class="lines">@@ -47,53 +47,44 @@
</span><span class="cx">
</span><span class="cx"> static const size_t superChunkSize = 32 * MB;
</span><span class="cx">
</span><del>- static const size_t xSmallMax = 64;
- static const size_t xSmallLineSize = 256;
- static const size_t xSmallLineMask = ~(xSmallLineSize - 1ul);
-
- static const size_t xSmallChunkSize = superChunkSize / 4;
- static const size_t xSmallChunkOffset = superChunkSize * 1 / 4;
- static const size_t xSmallChunkMask = ~(xSmallChunkSize - 1ul);
-
- static const size_t smallMax = 128;
- static const size_t smallLineSize = 256;
</del><ins>+ static const size_t smallMax = 256;
+ static const size_t smallLineSize = 512;
</ins><span class="cx"> static const size_t smallLineMask = ~(smallLineSize - 1ul);
</span><span class="cx">
</span><span class="cx"> static const size_t smallChunkSize = superChunkSize / 4;
</span><del>- static const size_t smallChunkOffset = superChunkSize * 2 / 4;
</del><ins>+ static const size_t smallChunkOffset = superChunkSize * 3 / 4;
</ins><span class="cx"> static const size_t smallChunkMask = ~(smallChunkSize - 1ul);
</span><span class="cx">
</span><del>- static const size_t mediumMax = 256;
- static const size_t mediumLineSize = 512;
</del><ins>+ static const size_t mediumMax = 1024;
+ static const size_t mediumLineSize = 2048;
</ins><span class="cx"> static const size_t mediumLineMask = ~(mediumLineSize - 1ul);
</span><span class="cx">
</span><span class="cx"> static const size_t mediumChunkSize = superChunkSize / 4;
</span><del>- static const size_t mediumChunkOffset = superChunkSize * 3 / 4;
</del><ins>+ static const size_t mediumChunkOffset = superChunkSize * 2 / 4;
</ins><span class="cx"> static const size_t mediumChunkMask = ~(mediumChunkSize - 1ul);
</span><span class="cx">
</span><del>- static const size_t largeChunkSize = superChunkSize / 4;
- static const size_t largeChunkOffset = superChunkSize * 0 / 4;
</del><ins>+ static const size_t largeChunkSize = superChunkSize / 2;
+ static const size_t largeChunkOffset = 0;
</ins><span class="cx"> static const size_t largeChunkMask = ~(largeChunkSize - 1ul);
</span><span class="cx">
</span><span class="cx"> static const size_t largeAlignment = 64;
</span><span class="cx"> static const size_t largeMax = largeChunkSize * 99 / 100; // Plenty of room for metadata.
</span><del>- static const size_t largeMin = mediumMax;
</del><ins>+ static const size_t largeMin = 1024;
</ins><span class="cx">
</span><span class="cx"> static const size_t segregatedFreeListSearchDepth = 16;
</span><span class="cx">
</span><span class="cx"> static const uintptr_t typeMask = (superChunkSize - 1) & ~((superChunkSize / 4) - 1); // 4 taggable chunks
</span><del>- static const uintptr_t xSmallType = (superChunkSize + xSmallChunkOffset) & typeMask;
</del><span class="cx"> static const uintptr_t smallType = (superChunkSize + smallChunkOffset) & typeMask;
</span><span class="cx"> static const uintptr_t mediumType = (superChunkSize + mediumChunkOffset) & typeMask;
</span><del>- static const uintptr_t largeType = (superChunkSize + largeChunkOffset) & typeMask;
-
</del><ins>+ static const uintptr_t largeTypeMask = ~(mediumType & smallType);
+ static const uintptr_t smallOrMediumTypeMask = mediumType & smallType;
+ static const uintptr_t smallOrMediumSmallTypeMask = smallType ^ mediumType; // Only valid if object is known to be small or medium.
+
</ins><span class="cx"> static const size_t deallocatorLogCapacity = 256;
</span><span class="cx">
</span><del>- static const size_t xSmallLineCacheCapacity = 32;
</del><span class="cx"> static const size_t smallLineCacheCapacity = 16;
</span><span class="cx"> static const size_t mediumLineCacheCapacity = 8;
</span><span class="cx">
</span><del>- static const size_t xSmallAllocatorLogCapacity = 32;
</del><span class="cx"> static const size_t smallAllocatorLogCapacity = 16;
</span><span class="cx"> static const size_t mediumAllocatorLogCapacity = 8;
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourcebmallocbmallocSmallAllocatorh"></a>
<div class="modfile"><h4>Modified: trunk/Source/bmalloc/bmalloc/SmallAllocator.h (167545 => 167546)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/bmalloc/bmalloc/SmallAllocator.h        2014-04-19 20:40:39 UTC (rev 167545)
+++ trunk/Source/bmalloc/bmalloc/SmallAllocator.h        2014-04-19 20:41:16 UTC (rev 167546)
</span><span class="lines">@@ -28,6 +28,7 @@
</span><span class="cx">
</span><span class="cx"> #include "BAssert.h"
</span><span class="cx"> #include "SmallChunk.h"
</span><ins>+#include "SmallLine.h"
</ins><span class="cx">
</span><span class="cx"> namespace bmalloc {
</span><span class="cx">
</span><span class="lines">@@ -84,7 +85,7 @@
</span><span class="cx"> --m_remaining;
</span><span class="cx"> char* result = m_ptr;
</span><span class="cx"> m_ptr += m_size;
</span><del>- BASSERT(objectType(result) == Small);
</del><ins>+ BASSERT(isSmall(result));
</ins><span class="cx"> return result;
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourcebmallocbmallocSmallTraitsh"></a>
<div class="modfile"><h4>Modified: trunk/Source/bmalloc/bmalloc/SmallTraits.h (167545 => 167546)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/bmalloc/bmalloc/SmallTraits.h        2014-04-19 20:40:39 UTC (rev 167545)
+++ trunk/Source/bmalloc/bmalloc/SmallTraits.h        2014-04-19 20:41:16 UTC (rev 167546)
</span><span class="lines">@@ -40,7 +40,7 @@
</span><span class="cx"> typedef Page<SmallTraits> Page;
</span><span class="cx">
</span><span class="cx"> static const size_t lineSize = smallLineSize;
</span><del>- static const size_t minimumObjectSize = xSmallMax + alignment;
</del><ins>+ static const size_t minimumObjectSize = alignment;
</ins><span class="cx"> static const size_t chunkSize = smallChunkSize;
</span><span class="cx"> static const size_t chunkOffset = smallChunkOffset;
</span><span class="cx"> static const uintptr_t chunkMask = smallChunkMask;
</span></span></pre></div>
<a id="trunkSourcebmallocbmallocVMHeapcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/bmalloc/bmalloc/VMHeap.cpp (167545 => 167546)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/bmalloc/bmalloc/VMHeap.cpp        2014-04-19 20:40:39 UTC (rev 167545)
+++ trunk/Source/bmalloc/bmalloc/VMHeap.cpp        2014-04-19 20:41:16 UTC (rev 167546)
</span><span class="lines">@@ -36,13 +36,6 @@
</span><span class="cx"> {
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void VMHeap::allocateXSmallChunk()
-{
- XSmallChunk* chunk = XSmallChunk::create();
- for (auto* it = chunk->begin(); it != chunk->end(); ++it)
- m_xSmallPages.push(it);
-}
-
</del><span class="cx"> void VMHeap::allocateSmallChunk()
</span><span class="cx"> {
</span><span class="cx"> SmallChunk* chunk = SmallChunk::create();
</span></span></pre></div>
<a id="trunkSourcebmallocbmallocVMHeaph"></a>
<div class="modfile"><h4>Modified: trunk/Source/bmalloc/bmalloc/VMHeap.h (167545 => 167546)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/bmalloc/bmalloc/VMHeap.h        2014-04-19 20:40:39 UTC (rev 167545)
+++ trunk/Source/bmalloc/bmalloc/VMHeap.h        2014-04-19 20:41:16 UTC (rev 167546)
</span><span class="lines">@@ -34,7 +34,6 @@
</span><span class="cx"> #include "SegregatedFreeList.h"
</span><span class="cx"> #include "SmallChunk.h"
</span><span class="cx"> #include "Vector.h"
</span><del>-#include "XSmallChunk.h"
</del><span class="cx">
</span><span class="cx"> namespace bmalloc {
</span><span class="cx">
</span><span class="lines">@@ -46,36 +45,24 @@
</span><span class="cx"> public:
</span><span class="cx"> VMHeap();
</span><span class="cx">
</span><del>- XSmallPage* allocateXSmallPage();
</del><span class="cx"> SmallPage* allocateSmallPage();
</span><span class="cx"> MediumPage* allocateMediumPage();
</span><span class="cx"> Range allocateLargeRange(size_t);
</span><span class="cx">
</span><del>- void deallocateXSmallPage(std::unique_lock<StaticMutex>&, XSmallPage*);
</del><span class="cx"> void deallocateSmallPage(std::unique_lock<StaticMutex>&, SmallPage*);
</span><span class="cx"> void deallocateMediumPage(std::unique_lock<StaticMutex>&, MediumPage*);
</span><span class="cx"> void deallocateLargeRange(std::unique_lock<StaticMutex>&, Range);
</span><span class="cx">
</span><span class="cx"> private:
</span><del>- void allocateXSmallChunk();
</del><span class="cx"> void allocateSmallChunk();
</span><span class="cx"> void allocateMediumChunk();
</span><span class="cx"> Range allocateLargeChunk();
</span><span class="cx">
</span><del>- Vector<XSmallPage*> m_xSmallPages;
</del><span class="cx"> Vector<SmallPage*> m_smallPages;
</span><span class="cx"> Vector<MediumPage*> m_mediumPages;
</span><span class="cx"> SegregatedFreeList m_largeRanges;
</span><span class="cx"> };
</span><span class="cx">
</span><del>-inline XSmallPage* VMHeap::allocateXSmallPage()
-{
- if (!m_xSmallPages.size())
- allocateXSmallChunk();
-
- return m_xSmallPages.pop();
-}
-
</del><span class="cx"> inline SmallPage* VMHeap::allocateSmallPage()
</span><span class="cx"> {
</span><span class="cx"> if (!m_smallPages.size())
</span><span class="lines">@@ -100,15 +87,6 @@
</span><span class="cx"> return range;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-inline void VMHeap::deallocateXSmallPage(std::unique_lock<StaticMutex>& lock, XSmallPage* page)
-{
- lock.unlock();
- vmDeallocatePhysicalPages(page->begin()->begin(), vmPageSize);
- lock.lock();
-
- m_xSmallPages.push(page);
-}
-
</del><span class="cx"> inline void VMHeap::deallocateSmallPage(std::unique_lock<StaticMutex>& lock, SmallPage* page)
</span><span class="cx"> {
</span><span class="cx"> lock.unlock();
</span></span></pre></div>
<a id="trunkSourcebmallocbmallocXSmallAllocatorh"></a>
<div class="delfile"><h4>Deleted: trunk/Source/bmalloc/bmalloc/XSmallAllocator.h (167545 => 167546)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/bmalloc/bmalloc/XSmallAllocator.h        2014-04-19 20:40:39 UTC (rev 167545)
+++ trunk/Source/bmalloc/bmalloc/XSmallAllocator.h        2014-04-19 20:41:16 UTC (rev 167546)
</span><span class="lines">@@ -1,111 +0,0 @@
</span><del>-/*
- * Copyright (C) 2014 Apple Inc. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. ``AS IS'' AND ANY
- * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
- * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
- * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#ifndef XSmallAllocator_h
-#define XSmallAllocator_h
-
-#include "BAssert.h"
-#include "XSmallChunk.h"
-
-namespace bmalloc {
-
-// Helper object for allocating XSmall objects.
-
-class XSmallAllocator {
-public:
- XSmallAllocator();
- XSmallAllocator(size_t);
-
- bool isNull() { return !m_ptr; }
- XSmallLine* line();
-
- bool canAllocate() { return !!m_remaining; }
- void* allocate();
-
- unsigned short objectCount();
- unsigned char derefCount();
- void refill(XSmallLine*);
-
-private:
- char* m_ptr;
- unsigned short m_size;
- unsigned char m_remaining;
- unsigned char m_maxObjectCount;
-};
-
-inline XSmallAllocator::XSmallAllocator()
- : m_ptr()
- , m_size()
- , m_remaining()
- , m_maxObjectCount()
-{
-}
-
-inline XSmallAllocator::XSmallAllocator(size_t size)
- : m_ptr()
- , m_size(size)
- , m_remaining()
- , m_maxObjectCount(xSmallLineSize / size)
-{
-}
-
-inline XSmallLine* XSmallAllocator::line()
-{
- return XSmallLine::get(canAllocate() ? m_ptr : m_ptr - 1);
-}
-
-inline void* XSmallAllocator::allocate()
-{
- BASSERT(m_remaining);
- BASSERT(m_size >= XSmallLine::minimumObjectSize);
-
- --m_remaining;
- char* result = m_ptr;
- m_ptr += m_size;
- BASSERT(objectType(result) == XSmall);
- return result;
-}
-
-inline unsigned short XSmallAllocator::objectCount()
-{
- return m_maxObjectCount - m_remaining;
-}
-
-inline unsigned char XSmallAllocator::derefCount()
-{
- return XSmallLine::maxRefCount - objectCount();
-}
-
-inline void XSmallAllocator::refill(XSmallLine* line)
-{
- BASSERT(!canAllocate());
- line->concurrentRef(XSmallLine::maxRefCount);
- m_ptr = line->begin();
- m_remaining = m_maxObjectCount;
-}
-
-} // namespace bmalloc
-
-#endif // XSmallAllocator_h
</del></span></pre></div>
<a id="trunkSourcebmallocbmallocXSmallChunkh"></a>
<div class="delfile"><h4>Deleted: trunk/Source/bmalloc/bmalloc/XSmallChunk.h (167545 => 167546)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/bmalloc/bmalloc/XSmallChunk.h        2014-04-19 20:40:39 UTC (rev 167545)
+++ trunk/Source/bmalloc/bmalloc/XSmallChunk.h        2014-04-19 20:41:16 UTC (rev 167546)
</span><span class="lines">@@ -1,40 +0,0 @@
</span><del>-/*
- * Copyright (C) 2014 Apple Inc. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. ``AS IS'' AND ANY
- * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
- * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
- * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#ifndef XSmallChunk_h
-#define XSmallChunk_h
-
-#include "Chunk.h"
-#include "XSmallLine.h"
-#include "XSmallPage.h"
-#include "XSmallTraits.h"
-
-namespace bmalloc {
-
-typedef Chunk<XSmallTraits> XSmallChunk;
-
-}; // namespace bmalloc
-
-#endif // XSmallChunk
</del></span></pre></div>
<a id="trunkSourcebmallocbmallocXSmallLineh"></a>
<div class="delfile"><h4>Deleted: trunk/Source/bmalloc/bmalloc/XSmallLine.h (167545 => 167546)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/bmalloc/bmalloc/XSmallLine.h        2014-04-19 20:40:39 UTC (rev 167545)
+++ trunk/Source/bmalloc/bmalloc/XSmallLine.h        2014-04-19 20:41:16 UTC (rev 167546)
</span><span class="lines">@@ -1,38 +0,0 @@
</span><del>-/*
- * Copyright (C) 2014 Apple Inc. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. ``AS IS'' AND ANY
- * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
- * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
- * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#ifndef XSmallLine_h
-#define XSmallLine_h
-
-#include "Line.h"
-#include "XSmallTraits.h"
-
-namespace bmalloc {
-
-typedef Line<XSmallTraits> XSmallLine;
-
-} // namespace bmalloc
-
-#endif // XSmallLine_h
</del></span></pre></div>
<a id="trunkSourcebmallocbmallocXSmallPageh"></a>
<div class="delfile"><h4>Deleted: trunk/Source/bmalloc/bmalloc/XSmallPage.h (167545 => 167546)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/bmalloc/bmalloc/XSmallPage.h        2014-04-19 20:40:39 UTC (rev 167545)
+++ trunk/Source/bmalloc/bmalloc/XSmallPage.h        2014-04-19 20:41:16 UTC (rev 167546)
</span><span class="lines">@@ -1,38 +0,0 @@
</span><del>-/*
- * Copyright (C) 2014 Apple Inc. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. ``AS IS'' AND ANY
- * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
- * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
- * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#ifndef XSmallPage_h
-#define XSmallPage_h
-
-#include "Page.h"
-#include "XSmallTraits.h"
-
-namespace bmalloc {
-
-typedef Page<XSmallTraits> XSmallPage;
-
-} // namespace bmalloc
-
-#endif // XSmallPage_h
</del></span></pre></div>
<a id="trunkSourcebmallocbmallocXSmallTraitsh"></a>
<div class="delfile"><h4>Deleted: trunk/Source/bmalloc/bmalloc/XSmallTraits.h (167545 => 167546)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/bmalloc/bmalloc/XSmallTraits.h        2014-04-19 20:40:39 UTC (rev 167545)
+++ trunk/Source/bmalloc/bmalloc/XSmallTraits.h        2014-04-19 20:41:16 UTC (rev 167546)
</span><span class="lines">@@ -1,51 +0,0 @@
</span><del>-/*
- * Copyright (C) 2014 Apple Inc. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. ``AS IS'' AND ANY
- * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR
- * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
- * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
- * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
- * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
- * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#ifndef XSmallTraits_h
-#define XSmallTraits_h
-
-#include "Sizes.h"
-
-namespace bmalloc {
-
-template<class Traits> class Chunk;
-template<class Traits> class Line;
-template<class Traits> class Page;
-
-struct XSmallTraits {
- typedef Chunk<XSmallTraits> Chunk;
- typedef Line<XSmallTraits> Line;
- typedef Page<XSmallTraits> Page;
-
- static const size_t lineSize = xSmallLineSize;
- static const size_t minimumObjectSize = alignment;
- static const size_t chunkSize = xSmallChunkSize;
- static const size_t chunkOffset = xSmallChunkOffset;
- static const uintptr_t chunkMask = xSmallChunkMask;
-};
-
-} // namespace bmalloc
-
-#endif // XSmallTraits_h
</del></span></pre></div>
<a id="trunkSourcebmallocbmallocbmalloch"></a>
<div class="modfile"><h4>Modified: trunk/Source/bmalloc/bmalloc/bmalloc.h (167545 => 167546)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/bmalloc/bmalloc/bmalloc.h        2014-04-19 20:40:39 UTC (rev 167545)
+++ trunk/Source/bmalloc/bmalloc/bmalloc.h        2014-04-19 20:41:16 UTC (rev 167546)
</span><span class="lines">@@ -50,13 +50,7 @@
</span><span class="cx"> return result;
</span><span class="cx">
</span><span class="cx"> size_t oldSize = 0;
</span><del>- switch (objectType(object)) {
- case XSmall: {
- // We don't have an exact size, but we can calculate a maximum.
- void* end = roundUpToMultipleOf<xSmallLineSize>(static_cast<char*>(object) + 1);
- oldSize = static_cast<char*>(end) - static_cast<char*>(object);
- break;
- }
</del><ins>+ switch(objectType(object)) {
</ins><span class="cx"> case Small: {
</span><span class="cx"> // We don't have an exact size, but we can calculate a maximum.
</span><span class="cx"> void* end = roundUpToMultipleOf<smallLineSize>(static_cast<char*>(object) + 1);
</span></span></pre></div>
<a id="trunkSourcebmallocbmallocxcodeprojprojectpbxproj"></a>
<div class="modfile"><h4>Modified: trunk/Source/bmalloc/bmalloc.xcodeproj/project.pbxproj (167545 => 167546)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/bmalloc/bmalloc.xcodeproj/project.pbxproj        2014-04-19 20:40:39 UTC (rev 167545)
+++ trunk/Source/bmalloc/bmalloc.xcodeproj/project.pbxproj        2014-04-19 20:41:16 UTC (rev 167546)
</span><span class="lines">@@ -11,11 +11,6 @@
</span><span class="cx">                 1400274A18F89C2300115C97 /* VMHeap.h in Headers */ = {isa = PBXBuildFile; fileRef = 144F7BFC18BFC517003537F3 /* VMHeap.h */; settings = {ATTRIBUTES = (Private, ); }; };
</span><span class="cx">                 1400274B18F89C3D00115C97 /* BoundaryTagInlines.h in Headers */ = {isa = PBXBuildFile; fileRef = 14105E7B18DBD7AF003A106E /* BoundaryTagInlines.h */; settings = {ATTRIBUTES = (Private, ); }; };
</span><span class="cx">                 1400274C18F89C3D00115C97 /* SegregatedFreeList.h in Headers */ = {isa = PBXBuildFile; fileRef = 146BEE1E18C841C50002D5A2 /* SegregatedFreeList.h */; settings = {ATTRIBUTES = (Private, ); }; };
</span><del>-                142FCC78190080B8009032D4 /* XSmallChunk.h in Headers */ = {isa = PBXBuildFile; fileRef = 142FCC74190080B8009032D4 /* XSmallChunk.h */; };
-                142FCC79190080B8009032D4 /* XSmallLine.h in Headers */ = {isa = PBXBuildFile; fileRef = 142FCC75190080B8009032D4 /* XSmallLine.h */; };
-                142FCC7A190080B8009032D4 /* XSmallPage.h in Headers */ = {isa = PBXBuildFile; fileRef = 142FCC76190080B8009032D4 /* XSmallPage.h */; };
-                142FCC7B190080B8009032D4 /* XSmallTraits.h in Headers */ = {isa = PBXBuildFile; fileRef = 142FCC77190080B8009032D4 /* XSmallTraits.h */; };
-                142FCC7D1900815E009032D4 /* XSmallAllocator.h in Headers */ = {isa = PBXBuildFile; fileRef = 142FCC7C1900815E009032D4 /* XSmallAllocator.h */; };
</del><span class="cx">                 143CB81C19022BC900B16A45 /* StaticMutex.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 143CB81A19022BC900B16A45 /* StaticMutex.cpp */; };
</span><span class="cx">                 143CB81D19022BC900B16A45 /* StaticMutex.h in Headers */ = {isa = PBXBuildFile; fileRef = 143CB81B19022BC900B16A45 /* StaticMutex.h */; };
</span><span class="cx">                 1448C30018F3754600502839 /* mbmalloc.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1448C2FF18F3754300502839 /* mbmalloc.cpp */; };
</span><span class="lines">@@ -88,11 +83,6 @@
</span><span class="cx">                 1417F64F18B7280C0076FA3F /* Syscall.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = Syscall.h; path = bmalloc/Syscall.h; sourceTree = "<group>"; };
</span><span class="cx">                 1417F65218BA88A00076FA3F /* AsyncTask.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = AsyncTask.h; path = bmalloc/AsyncTask.h; sourceTree = "<group>"; };
</span><span class="cx">                 1421A87718EE462A00B4DD68 /* Algorithm.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; name = Algorithm.h; path = bmalloc/Algorithm.h; sourceTree = "<group>"; };
</span><del>-                142FCC74190080B8009032D4 /* XSmallChunk.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XSmallChunk.h; path = bmalloc/XSmallChunk.h; sourceTree = "<group>"; };
-                142FCC75190080B8009032D4 /* XSmallLine.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XSmallLine.h; path = bmalloc/XSmallLine.h; sourceTree = "<group>"; };
-                142FCC76190080B8009032D4 /* XSmallPage.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XSmallPage.h; path = bmalloc/XSmallPage.h; sourceTree = "<group>"; };
-                142FCC77190080B8009032D4 /* XSmallTraits.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XSmallTraits.h; path = bmalloc/XSmallTraits.h; sourceTree = "<group>"; };
-                142FCC7C1900815E009032D4 /* XSmallAllocator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = XSmallAllocator.h; path = bmalloc/XSmallAllocator.h; sourceTree = "<group>"; };
</del><span class="cx">                 143CB81A19022BC900B16A45 /* StaticMutex.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = StaticMutex.cpp; path = bmalloc/StaticMutex.cpp; sourceTree = "<group>"; };
</span><span class="cx">                 143CB81B19022BC900B16A45 /* StaticMutex.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = StaticMutex.h; path = bmalloc/StaticMutex.h; sourceTree = "<group>"; };
</span><span class="cx">                 143E29E918CAE8BE00FE8A0F /* MediumPage.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = MediumPage.h; path = bmalloc/MediumPage.h; sourceTree = "<group>"; };
</span><span class="lines">@@ -207,10 +197,6 @@
</span><span class="cx">                                 1452478618BC757C00F80098 /* SmallLine.h */,
</span><span class="cx">                                 143E29ED18CAE90500FE8A0F /* SmallPage.h */,
</span><span class="cx">                                 147AAA9718CE5FB6002201E4 /* SmallTraits.h */,
</span><del>-                                142FCC74190080B8009032D4 /* XSmallChunk.h */,
-                                142FCC75190080B8009032D4 /* XSmallLine.h */,
-                                142FCC76190080B8009032D4 /* XSmallPage.h */,
-                                142FCC77190080B8009032D4 /* XSmallTraits.h */,
</del><span class="cx">                         );
</span><span class="cx">                         name = "heap: small | medium";
</span><span class="cx">                         sourceTree = "<group>";
</span><span class="lines">@@ -253,7 +239,6 @@
</span><span class="cx">                                 145F685A179DC90200D65598 /* Deallocator.h */,
</span><span class="cx">                                 1413E47018A0661700546D68 /* MediumAllocator.h */,
</span><span class="cx">                                 1413E462189DE1CD00546D68 /* SmallAllocator.h */,
</span><del>-                                142FCC7C1900815E009032D4 /* XSmallAllocator.h */,
</del><span class="cx">                         );
</span><span class="cx">                         name = cache;
</span><span class="cx">                         sourceTree = "<group>";
</span><span class="lines">@@ -308,7 +293,6 @@
</span><span class="cx">                         isa = PBXHeadersBuildPhase;
</span><span class="cx">                         buildActionMask = 2147483647;
</span><span class="cx">                         files = (
</span><del>-                                142FCC7B190080B8009032D4 /* XSmallTraits.h in Headers */,
</del><span class="cx">                                 14DD78B518F48D6B00950702 /* Line.h in Headers */,
</span><span class="cx">                                 14DD78CF18F48D7500950702 /* Vector.h in Headers */,
</span><span class="cx">                                 14C919C918FCC59F0028DB43 /* BPlatform.h in Headers */,
</span><span class="lines">@@ -317,7 +301,6 @@
</span><span class="cx">                                 14DD78CC18F48D7500950702 /* PerThread.h in Headers */,
</span><span class="cx">                                 14DD78B418F48D6B00950702 /* Chunk.h in Headers */,
</span><span class="cx">                                 14DD78CA18F48D7500950702 /* Mutex.h in Headers */,
</span><del>-                                142FCC7D1900815E009032D4 /* XSmallAllocator.h in Headers */,
</del><span class="cx">                                 143CB81D19022BC900B16A45 /* StaticMutex.h in Headers */,
</span><span class="cx">                                 14DD78D118F48EC600950702 /* XLargeChunk.h in Headers */,
</span><span class="cx">                                 14DD78B918F48D6B00950702 /* MediumTraits.h in Headers */,
</span><span class="lines">@@ -339,14 +322,11 @@
</span><span class="cx">                                 14DD78BB18F48D6B00950702 /* SmallChunk.h in Headers */,
</span><span class="cx">                                 14DD78C918F48D7500950702 /* Inline.h in Headers */,
</span><span class="cx">                                 1400274A18F89C2300115C97 /* VMHeap.h in Headers */,
</span><del>-                                142FCC7A190080B8009032D4 /* XSmallPage.h in Headers */,
</del><span class="cx">                                 1400274918F89C1300115C97 /* Heap.h in Headers */,
</span><span class="cx">                                 14DD78B818F48D6B00950702 /* MediumPage.h in Headers */,
</span><span class="cx">                                 14DD78C518F48D7500950702 /* Algorithm.h in Headers */,
</span><span class="cx">                                 14DD78BD18F48D6B00950702 /* SmallPage.h in Headers */,
</span><span class="cx">                                 1400274B18F89C3D00115C97 /* BoundaryTagInlines.h in Headers */,
</span><del>-                                142FCC79190080B8009032D4 /* XSmallLine.h in Headers */,
-                                142FCC78190080B8009032D4 /* XSmallChunk.h in Headers */,
</del><span class="cx">                                 14DD788E18F48CCD00950702 /* BoundaryTag.h in Headers */,
</span><span class="cx">                                 14DD78C818F48D7500950702 /* FixedVector.h in Headers */,
</span><span class="cx">                                 14DD78B718F48D6B00950702 /* MediumLine.h in Headers */,
</span></span></pre>
</div>
</div>
</body>
</html>