aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/compiler/qv4instr_moth_p.h
diff options
context:
space:
mode:
authorErik Verbruggen <erik.verbruggen@qt.io>2017-11-21 10:10:36 +0100
committerLars Knoll <lars.knoll@qt.io>2017-11-23 15:05:25 +0000
commit458daae517b4465fafb315323e9c727f1655764d (patch)
tree623a4a9a6268f08c53cb2369268c98bda966d1c6 /src/qml/compiler/qv4instr_moth_p.h
parent1f5c79c59aa43e416778a2046e4121731b34bb6a (diff)
V4: Change CallValue to have the value on the stack
We used to store the value-to-be-called in the accumulator. So the generated bytecode looked like: LoadReg r1 CallValue() The first thing done in CallValue is to store the accumulator. So by not loading the accumulator, we can actually remove the subsequent store, which results in less interpreter instructions and one less store in CallValue. Change-Id: Icc7c8a5449bf369b9226d66bc6055cb705ef660e Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Diffstat (limited to 'src/qml/compiler/qv4instr_moth_p.h')
-rw-r--r--src/qml/compiler/qv4instr_moth_p.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/qml/compiler/qv4instr_moth_p.h b/src/qml/compiler/qv4instr_moth_p.h
index 06cf34481c..0c1b5e240c 100644
--- a/src/qml/compiler/qv4instr_moth_p.h
+++ b/src/qml/compiler/qv4instr_moth_p.h
@@ -109,7 +109,7 @@ QT_BEGIN_NAMESPACE
#define INSTR_LoadElement(op) INSTRUCTION(op, LoadElement, 2, base, index)
#define INSTR_LoadElementA(op) INSTRUCTION(op, LoadElementA, 1, base)
#define INSTR_StoreElement(op) INSTRUCTION(op, StoreElement, 2, base, index)
-#define INSTR_CallValue(op) INSTRUCTION(op, CallValue, 2, argc, argv)
+#define INSTR_CallValue(op) INSTRUCTION(op, CallValue, 3, name, argc, argv)
#define INSTR_CallProperty(op) INSTRUCTION(op, CallProperty, 4, name, base, argc, argv)
#define INSTR_CallPropertyLookup(op) INSTRUCTION(op, CallPropertyLookup, 4, lookupIndex, base, argc, argv)
#define INSTR_CallElement(op) INSTRUCTION(op, CallElement, 4, base, index, argc, argv)