This reverts commit
2bd6e240a3c2b3dc7a2c81c639d4f30e4dfd685f.
This doesn't work properly as the code generator will not keep those
initializations at the beginning of the function, resulting in
uninitialized values in ctx->locals[], which gives valgrind warnings
when they're marked.
Change-Id: I81501e0ea80e7f76b7d9112fea261e406084b69b
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
function->LOCAL(local);
unsigned t = entryBlock->newTemp();
(*it).index = t;
- entryBlock->MOVE(entryBlock->TEMP(t), entryBlock->CONST(V4IR::UndefinedType, 0));
}
} else {
if (!_env->isStrict) {
uint argc = argumentCount;
locals = (Value *)(this + 1);
+ if (function->varCount)
+ std::fill(locals, locals + function->varCount, Value::undefinedValue());
if (needsOwnArguments()) {
Value *args = arguments;