aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/jsruntime/qv4identifiertable.cpp
diff options
context:
space:
mode:
authorLars Knoll <lars.knoll@qt.io>2017-02-15 15:40:27 +0100
committerLars Knoll <lars.knoll@qt.io>2017-03-09 08:59:23 +0000
commite772081db104e09e95ed09e8d1f0076e07fc53f6 (patch)
tree1261b71d754b8de8520335ee545707e6d64b544e /src/qml/jsruntime/qv4identifiertable.cpp
parent2a554434a571dcefd26cf10ef8c5ae8b3b7d66db (diff)
Incremental garbage collection
Add an incremental mode to the garbage collector, that will get used for many collections. This should significantly reduce average stop times for GC. Make sure that manual calls to gc() still do a full collection, to ensure consistency and keep tests that rely on gc() working. Change-Id: I87b13529377b7639ce993dbd99e85ff0a555acd8 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Diffstat (limited to 'src/qml/jsruntime/qv4identifiertable.cpp')
-rw-r--r--src/qml/jsruntime/qv4identifiertable.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/qml/jsruntime/qv4identifiertable.cpp b/src/qml/jsruntime/qv4identifiertable.cpp
index 3def6defbf..d3ef238716 100644
--- a/src/qml/jsruntime/qv4identifiertable.cpp
+++ b/src/qml/jsruntime/qv4identifiertable.cpp
@@ -81,6 +81,7 @@ void IdentifierTable::addEntry(Heap::String *str)
str->identifier = new Identifier;
str->identifier->string = str->toQString();
str->identifier->hashValue = hash;
+ str->setMarkBit();
bool grow = (alloc <= size*2);