aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/compiler/qv4isel_masm.cpp
diff options
context:
space:
mode:
authorSimon Hausmann <simon.hausmann@digia.com>2013-08-15 15:54:36 +0200
committerLars Knoll <lars.knoll@digia.com>2013-08-16 10:14:13 +0200
commitb88626a3a59f7dcd01be6fe2a8236b14ca1176f5 (patch)
treef3a1f6db220f2d6a7d71f2ddc7b466e205658f40 /src/qml/compiler/qv4isel_masm.cpp
parent214680abec598bc01c4f90b3cecc60c7968c0c41 (diff)
Ported regular expressions over to be run-time generated data
Change-Id: I04e693d4923c97c3d869a5beb17011f6aad85f03 Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Diffstat (limited to 'src/qml/compiler/qv4isel_masm.cpp')
-rw-r--r--src/qml/compiler/qv4isel_masm.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/qml/compiler/qv4isel_masm.cpp b/src/qml/compiler/qv4isel_masm.cpp
index 3907cb1300..d93a67a163 100644
--- a/src/qml/compiler/qv4isel_masm.cpp
+++ b/src/qml/compiler/qv4isel_masm.cpp
@@ -1056,10 +1056,8 @@ void InstructionSelection::loadString(const QString &str, V4IR::Temp *targetTemp
void InstructionSelection::loadRegexp(V4IR::RegExp *sourceRegexp, V4IR::Temp *targetTemp)
{
- Value v = Value::fromObject(engine()->newRegExpObject(*sourceRegexp->value,
- sourceRegexp->flags));
- _vmFunction->generatedValues.append(v);
- _as->storeValue(v, targetTemp);
+ int id = jsUnitGenerator.registerRegExp(sourceRegexp);
+ generateFunctionCall(Assembler::Void, __qmljs_lookup_runtime_regexp, Assembler::ContextRegister, Assembler::PointerToValue(targetTemp), Assembler::TrustedImm32(id));
}
void InstructionSelection::getActivationProperty(const V4IR::Name *name, V4IR::Temp *temp)