aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/compiler/qqmlirbuilder.cpp
diff options
context:
space:
mode:
authorLars Knoll <lars.knoll@qt.io>2017-05-11 10:09:12 +0200
committerErik Verbruggen <erik.verbruggen@qt.io>2017-06-09 07:55:33 +0000
commit5efbd7165d6867aa376f23c20edcfe49e80518c6 (patch)
tree2cb510332dcc5973c4c017775567e25677c01e0d /src/qml/compiler/qqmlirbuilder.cpp
parent4ea6d985fa76786a965443f814f3f9b59620e056 (diff)
Change temp allocation when generating IR
For functions that won't get optimized, it's useful to limit the number of temporaries as much as possible. Change-Id: I6e9be3129c064fdc4c01e1ec6f1617e901c05935 Reviewed-by: Erik Verbruggen <erik.verbruggen@qt.io> Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Diffstat (limited to 'src/qml/compiler/qqmlirbuilder.cpp')
-rw-r--r--src/qml/compiler/qqmlirbuilder.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/qml/compiler/qqmlirbuilder.cpp b/src/qml/compiler/qqmlirbuilder.cpp
index 16eee50cf9..57cb4c607c 100644
--- a/src/qml/compiler/qqmlirbuilder.cpp
+++ b/src/qml/compiler/qqmlirbuilder.cpp
@@ -1948,7 +1948,8 @@ QV4::IR::Expr *JSCodeGen::fallbackNameLookup(const QString &name, int line, int
QQmlTypeNameCache::Result r = imports->query(name);
if (r.isValid()) {
if (r.scriptIndex != -1) {
- return subscript(_block->TEMP(_importedScriptsTemp), _block->CONST(QV4::IR::SInt32Type, r.scriptIndex));
+ return _block->SUBSCRIPT(_block->TEMP(_importedScriptsTemp),
+ _block->CONST(QV4::IR::SInt32Type, r.scriptIndex));
} else if (r.type) {
QV4::IR::Name *typeName = _block->NAME(name, line, col);
// Make sure the run-time loads this through the more efficient singleton getter.