Bug 1433007 - (part 1) Make growAllocableSpace more strict about its argument r=sfink
authorPaul Bone <pbone@mozilla.com>
Fri, 15 Feb 2019 04:29:10 +0000
changeset 459492 9dffda69dd2ae0337e543e903c64673ff7b6a79a
parent 459474 abe819688f32e900a19323e409ded63fdce789a4
child 459493 b2d8b986d422ab542e5704677b0f7bb88f82c97f
push id111964
push usercsabou@mozilla.com
push dateFri, 15 Feb 2019 18:54:44 +0000
treeherdermozilla-inbound@db3c4f905082 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerssfink
bugs1433007
milestone67.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 1433007 - (part 1) Make growAllocableSpace more strict about its argument r=sfink Differential Revision: https://phabricator.services.mozilla.com/D19618
js/src/gc/Nursery.cpp
--- a/js/src/gc/Nursery.cpp
+++ b/js/src/gc/Nursery.cpp
@@ -1179,17 +1179,17 @@ void js::Nursery::maybeResizeNursery(JS:
     unsigned lowLimit = Max(1u, maxChunkCount() / 2);
     unsigned highLimit = maxChunkCount() - 1u;
 
     shrinkAllocableSpace(mozilla::Clamp(newChunkCount, lowLimit, highLimit));
   }
 }
 
 void js::Nursery::growAllocableSpace(unsigned newCount) {
-  MOZ_ASSERT(newCount >= currentChunk_);
+  MOZ_ASSERT(newCount > currentChunk_);
   maxChunkCount_ = newCount;
 }
 
 void js::Nursery::freeChunksFrom(unsigned firstFreeChunk) {
   MOZ_ASSERT(firstFreeChunk < chunks_.length());
   {
     AutoLockGC lock(runtime());
     for (unsigned i = firstFreeChunk; i < chunks_.length(); i++) {