OLD | NEW |
1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 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 578 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
589 // a2 points to call data as expected by Arguments | 589 // a2 points to call data as expected by Arguments |
590 // (refer to layout above). | 590 // (refer to layout above). |
591 __ Addu(a2, sp, Operand(2 * kPointerSize)); | 591 __ Addu(a2, sp, Operand(2 * kPointerSize)); |
592 | 592 |
593 Object* callback = optimization.api_call_info()->callback(); | 593 Object* callback = optimization.api_call_info()->callback(); |
594 Address api_function_address = v8::ToCData<Address>(callback); | 594 Address api_function_address = v8::ToCData<Address>(callback); |
595 ApiFunction fun(api_function_address); | 595 ApiFunction fun(api_function_address); |
596 | 596 |
597 const int kApiStackSpace = 4; | 597 const int kApiStackSpace = 4; |
598 | 598 |
| 599 FrameScope frame_scope(masm, StackFrame::MANUAL); |
599 __ EnterExitFrame(false, kApiStackSpace); | 600 __ EnterExitFrame(false, kApiStackSpace); |
600 | 601 |
601 // NOTE: the O32 abi requires a0 to hold a special pointer when returning a | 602 // NOTE: the O32 abi requires a0 to hold a special pointer when returning a |
602 // struct from the function (which is currently the case). This means we pass | 603 // struct from the function (which is currently the case). This means we pass |
603 // the first argument in a1 instead of a0. TryCallApiFunctionAndReturn | 604 // the first argument in a1 instead of a0. TryCallApiFunctionAndReturn |
604 // will handle setting up a0. | 605 // will handle setting up a0. |
605 | 606 |
606 // a1 = v8::Arguments& | 607 // a1 = v8::Arguments& |
607 // Arguments is built at sp + 1 (sp is a reserved spot for ra). | 608 // Arguments is built at sp + 1 (sp is a reserved spot for ra). |
608 __ Addu(a1, sp, kPointerSize); | 609 __ Addu(a1, sp, kPointerSize); |
(...skipping 644 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1253 Address getter_address = v8::ToCData<Address>(callback->getter()); | 1254 Address getter_address = v8::ToCData<Address>(callback->getter()); |
1254 ApiFunction fun(getter_address); | 1255 ApiFunction fun(getter_address); |
1255 | 1256 |
1256 // NOTE: the O32 abi requires a0 to hold a special pointer when returning a | 1257 // NOTE: the O32 abi requires a0 to hold a special pointer when returning a |
1257 // struct from the function (which is currently the case). This means we pass | 1258 // struct from the function (which is currently the case). This means we pass |
1258 // the arguments in a1-a2 instead of a0-a1. TryCallApiFunctionAndReturn | 1259 // the arguments in a1-a2 instead of a0-a1. TryCallApiFunctionAndReturn |
1259 // will handle setting up a0. | 1260 // will handle setting up a0. |
1260 | 1261 |
1261 const int kApiStackSpace = 1; | 1262 const int kApiStackSpace = 1; |
1262 | 1263 |
| 1264 FrameScope frame_scope(masm(), StackFrame::MANUAL); |
1263 __ EnterExitFrame(false, kApiStackSpace); | 1265 __ EnterExitFrame(false, kApiStackSpace); |
| 1266 |
1264 // Create AccessorInfo instance on the stack above the exit frame with | 1267 // Create AccessorInfo instance on the stack above the exit frame with |
1265 // scratch2 (internal::Object **args_) as the data. | 1268 // scratch2 (internal::Object **args_) as the data. |
1266 __ sw(a2, MemOperand(sp, kPointerSize)); | 1269 __ sw(a2, MemOperand(sp, kPointerSize)); |
1267 // a2 (second argument - see note above) = AccessorInfo& | 1270 // a2 (second argument - see note above) = AccessorInfo& |
1268 __ Addu(a2, sp, kPointerSize); | 1271 __ Addu(a2, sp, kPointerSize); |
1269 | 1272 |
1270 // Emitting a stub call may try to allocate (if the code is not | 1273 // Emitting a stub call may try to allocate (if the code is not |
1271 // already generated). Do not allow the assembler to perform a | 1274 // already generated). Do not allow the assembler to perform a |
1272 // garbage collection but instead return the allocation failure | 1275 // garbage collection but instead return the allocation failure |
1273 // object. | 1276 // object. |
(...skipping 3220 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4494 masm->isolate()->builtins()->KeyedStoreIC_MissForceGeneric(); | 4497 masm->isolate()->builtins()->KeyedStoreIC_MissForceGeneric(); |
4495 __ Jump(ic, RelocInfo::CODE_TARGET); | 4498 __ Jump(ic, RelocInfo::CODE_TARGET); |
4496 } | 4499 } |
4497 | 4500 |
4498 | 4501 |
4499 #undef __ | 4502 #undef __ |
4500 | 4503 |
4501 } } // namespace v8::internal | 4504 } } // namespace v8::internal |
4502 | 4505 |
4503 #endif // V8_TARGET_ARCH_MIPS | 4506 #endif // V8_TARGET_ARCH_MIPS |
OLD | NEW |