OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 1304 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1315 } | 1315 } |
1316 __ push(scratch3()); | 1316 __ push(scratch3()); |
1317 __ LoadRoot(scratch3(), Heap::kUndefinedValueRootIndex); | 1317 __ LoadRoot(scratch3(), Heap::kUndefinedValueRootIndex); |
1318 __ mov(scratch4(), scratch3()); | 1318 __ mov(scratch4(), scratch3()); |
1319 __ Push(scratch3(), scratch4()); | 1319 __ Push(scratch3(), scratch4()); |
1320 __ mov(scratch4(), | 1320 __ mov(scratch4(), |
1321 Operand(ExternalReference::isolate_address(isolate()))); | 1321 Operand(ExternalReference::isolate_address(isolate()))); |
1322 __ Push(scratch4(), reg); | 1322 __ Push(scratch4(), reg); |
1323 __ mov(scratch2(), sp); // scratch2 = PropertyAccessorInfo::args_ | 1323 __ mov(scratch2(), sp); // scratch2 = PropertyAccessorInfo::args_ |
1324 __ push(name()); | 1324 __ push(name()); |
1325 __ mov(r0, sp); // r0 = Handle<Name> | |
1326 | 1325 |
1327 const int kApiStackSpace = 1; | 1326 // Abi for CallApiGetter |
1328 FrameScope frame_scope(masm(), StackFrame::MANUAL); | 1327 Register getter_address_reg = r3; |
1329 __ EnterExitFrame(false, kApiStackSpace); | 1328 Register thunk_last_arg = r2; |
1330 | 1329 |
1331 // Create PropertyAccessorInfo instance on the stack above the exit frame with | |
1332 // scratch2 (internal::Object** args_) as the data. | |
1333 __ str(scratch2(), MemOperand(sp, 1 * kPointerSize)); | |
1334 __ add(r1, sp, Operand(1 * kPointerSize)); // r1 = AccessorInfo& | |
1335 | |
1336 const int kStackUnwindSpace = PropertyCallbackArguments::kArgsLength + 1; | |
1337 Address getter_address = v8::ToCData<Address>(callback->getter()); | 1330 Address getter_address = v8::ToCData<Address>(callback->getter()); |
1338 | |
1339 ApiFunction fun(getter_address); | 1331 ApiFunction fun(getter_address); |
1340 ExternalReference::Type type = ExternalReference::DIRECT_GETTER_CALL; | 1332 ExternalReference::Type type = ExternalReference::DIRECT_GETTER_CALL; |
1341 ExternalReference ref = ExternalReference(&fun, type, isolate()); | 1333 ExternalReference ref = ExternalReference(&fun, type, isolate()); |
1342 Register getter_address_reg = r3; | |
1343 Register thunk_last_arg = r2; | |
1344 __ mov(getter_address_reg, Operand(ref)); | 1334 __ mov(getter_address_reg, Operand(ref)); |
1345 __ mov(thunk_last_arg, Operand(reinterpret_cast<int32_t>(getter_address))); | 1335 __ mov(thunk_last_arg, Operand(reinterpret_cast<int32_t>(getter_address))); |
1346 | 1336 |
1347 Address thunk_address = FUNCTION_ADDR(&InvokeAccessorGetterCallback); | 1337 CallApiGetterStub stub; |
1348 ExternalReference::Type thunk_type = | 1338 __ TailCallStub(&stub); |
1349 ExternalReference::PROFILING_GETTER_CALL; | |
1350 ApiFunction thunk_fun(thunk_address); | |
1351 ExternalReference thunk_ref = ExternalReference(&thunk_fun, thunk_type, | |
1352 isolate()); | |
1353 __ CallApiFunctionAndReturn(getter_address_reg, | |
1354 thunk_ref, | |
1355 thunk_last_arg, | |
1356 kStackUnwindSpace, | |
1357 MemOperand(fp, 6 * kPointerSize), | |
1358 NULL); | |
1359 } | 1339 } |
1360 | 1340 |
1361 | 1341 |
1362 void LoadStubCompiler::GenerateLoadInterceptor( | 1342 void LoadStubCompiler::GenerateLoadInterceptor( |
1363 Register holder_reg, | 1343 Register holder_reg, |
1364 Handle<Object> object, | 1344 Handle<Object> object, |
1365 Handle<JSObject> interceptor_holder, | 1345 Handle<JSObject> interceptor_holder, |
1366 LookupResult* lookup, | 1346 LookupResult* lookup, |
1367 Handle<Name> name) { | 1347 Handle<Name> name) { |
1368 ASSERT(interceptor_holder->HasNamedInterceptor()); | 1348 ASSERT(interceptor_holder->HasNamedInterceptor()); |
(...skipping 751 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2120 // ----------------------------------- | 2100 // ----------------------------------- |
2121 TailCallBuiltin(masm, Builtins::kKeyedLoadIC_Miss); | 2101 TailCallBuiltin(masm, Builtins::kKeyedLoadIC_Miss); |
2122 } | 2102 } |
2123 | 2103 |
2124 | 2104 |
2125 #undef __ | 2105 #undef __ |
2126 | 2106 |
2127 } } // namespace v8::internal | 2107 } } // namespace v8::internal |
2128 | 2108 |
2129 #endif // V8_TARGET_ARCH_ARM | 2109 #endif // V8_TARGET_ARCH_ARM |
OLD | NEW |