| Index: src/ic/mips/handler-compiler-mips.cc
|
| diff --git a/src/ic/mips/handler-compiler-mips.cc b/src/ic/mips/handler-compiler-mips.cc
|
| index 49c289cfac53bf59c9e5a92503433af0a6263208..93106ea0e15c8f0d6ac3f069c89938bed190d752 100644
|
| --- a/src/ic/mips/handler-compiler-mips.cc
|
| +++ b/src/ic/mips/handler-compiler-mips.cc
|
| @@ -662,11 +662,19 @@ void NamedLoadHandlerCompiler::GenerateLoadInterceptor(Register holder_reg) {
|
|
|
|
|
| Handle<Code> NamedStoreHandlerCompiler::CompileStoreCallback(
|
| - Handle<JSObject> object, Handle<Name> name, int accessor_index) {
|
| + Handle<JSObject> object, Handle<Name> name,
|
| + Handle<ExecutableAccessorInfo> callback) {
|
| Register holder_reg = Frontend(name);
|
|
|
| __ Push(receiver(), holder_reg); // Receiver.
|
| - __ li(at, Operand(Smi::FromInt(accessor_index)));
|
| + // If the callback cannot leak, then push the callback directly,
|
| + // otherwise wrap it in a weak cell.
|
| + if (callback->data()->IsUndefined() || callback->data()->IsSmi()) {
|
| + __ li(at, Operand(callback));
|
| + } else {
|
| + Handle<WeakCell> cell = isolate()->factory()->NewWeakCell(callback);
|
| + __ li(at, Operand(cell));
|
| + }
|
| __ push(at);
|
| __ li(at, Operand(name));
|
| __ Push(at, value());
|
|
|