Index: src/x64/stub-cache-x64.cc |
=================================================================== |
--- src/x64/stub-cache-x64.cc (revision 3440) |
+++ src/x64/stub-cache-x64.cc (working copy) |
@@ -987,10 +987,10 @@ |
} |
-Object* LoadStubCompiler::CompileLoadCallback(JSObject* object, |
+Object* LoadStubCompiler::CompileLoadCallback(String* name, |
+ JSObject* object, |
JSObject* holder, |
- AccessorInfo* callback, |
- String* name) { |
+ AccessorInfo* callback) { |
// ----------- S t a t e ------------- |
// -- rcx : name |
// -- rsp[0] : return address |
@@ -999,8 +999,11 @@ |
Label miss; |
__ movq(rax, Operand(rsp, kPointerSize)); |
- GenerateLoadCallback(object, holder, rax, rcx, rbx, rdx, |
- callback, name, &miss); |
+ Failure* failure = Failure::InternalError(); |
+ bool success = GenerateLoadCallback(object, holder, rax, rcx, rbx, rdx, |
+ callback, name, &miss, &failure); |
+ if (!success) return failure; |
+ |
__ bind(&miss); |
GenerateLoadMiss(masm(), Code::LOAD_IC); |
@@ -1154,8 +1157,11 @@ |
__ Cmp(rax, Handle<String>(name)); |
__ j(not_equal, &miss); |
- GenerateLoadCallback(receiver, holder, rcx, rax, rbx, rdx, |
- callback, name, &miss); |
+ Failure* failure = Failure::InternalError(); |
+ bool success = GenerateLoadCallback(receiver, holder, rcx, rax, rbx, rdx, |
+ callback, name, &miss, &failure); |
+ if (!success) return failure; |
+ |
__ bind(&miss); |
__ DecrementCounter(&Counters::keyed_load_callback, 1); |
GenerateLoadMiss(masm(), Code::KEYED_LOAD_IC); |
@@ -1610,7 +1616,7 @@ |
} |
-void StubCompiler::GenerateLoadCallback(JSObject* object, |
+bool StubCompiler::GenerateLoadCallback(JSObject* object, |
JSObject* holder, |
Register receiver, |
Register name_reg, |
@@ -1618,7 +1624,8 @@ |
Register scratch2, |
AccessorInfo* callback, |
String* name, |
- Label* miss) { |
+ Label* miss, |
+ Failure** failure) { |
// Check that the receiver isn't a smi. |
__ JumpIfSmi(receiver, miss); |
@@ -1641,6 +1648,8 @@ |
ExternalReference load_callback_property = |
ExternalReference(IC_Utility(IC::kLoadCallbackProperty)); |
__ TailCallRuntime(load_callback_property, 5, 1); |
+ |
+ return true; |
} |