diff options
author | Simon Hausmann <simon.hausmann@qt.io> | 2017-10-05 11:02:36 +0200 |
---|---|---|
committer | Simon Hausmann <simon.hausmann@qt.io> | 2017-10-06 12:56:11 +0000 |
commit | 55ecfd409ca6aa8018be8cc2697b27928fbd4cc2 (patch) | |
tree | 22f2eb3c976f0a305c37856d167f89fdca8667f8 /src/qml/jsruntime/qv4engine_p.h | |
parent | 080a5c705aa9c04a332c2f95a216853b098d9d6b (diff) |
Simplify compilation unit tracking in the execution engine
Instead of collecting all compilation units in a hash, let's collect
linked units in a doubly-linked lists that makes the removal at
destruction time dramatically cheaper.
Change-Id: I9fd59600d082be3566f605d90f14a86a58ac9296
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Diffstat (limited to 'src/qml/jsruntime/qv4engine_p.h')
-rw-r--r-- | src/qml/jsruntime/qv4engine_p.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/qml/jsruntime/qv4engine_p.h b/src/qml/jsruntime/qv4engine_p.h index 688a58e345..fee06ebc58 100644 --- a/src/qml/jsruntime/qv4engine_p.h +++ b/src/qml/jsruntime/qv4engine_p.h @@ -59,6 +59,7 @@ #ifndef V4_BOOTSTRAP # include <private/qv8engine_p.h> +# include <private/qv4compileddata_p.h> #endif namespace WTF { @@ -318,7 +319,9 @@ public: String *id_buffer() const { return reinterpret_cast<String *>(jsStrings + String_buffer); } String *id_lastIndex() const { return reinterpret_cast<String *>(jsStrings + String_lastIndex); } - QSet<CompiledData::CompilationUnit*> compilationUnits; +#ifndef V4_BOOTSTRAP + QIntrusiveList<CompiledData::CompilationUnit, &CompiledData::CompilationUnit::nextCompilationUnit> compilationUnits; +#endif quint32 m_engineId; |