| 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 4485 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4496 __ InvokeBuiltin(Builtins::INSTANCE_OF, CALL_FUNCTION); | 4496 __ InvokeBuiltin(Builtins::INSTANCE_OF, CALL_FUNCTION); |
| 4497 } | 4497 } |
| 4498 __ cmp(r0, Operand::Zero()); | 4498 __ cmp(r0, Operand::Zero()); |
| 4499 __ LoadRoot(r0, Heap::kTrueValueRootIndex, eq); | 4499 __ LoadRoot(r0, Heap::kTrueValueRootIndex, eq); |
| 4500 __ LoadRoot(r0, Heap::kFalseValueRootIndex, ne); | 4500 __ LoadRoot(r0, Heap::kFalseValueRootIndex, ne); |
| 4501 __ Ret(HasArgsInRegisters() ? 0 : 2); | 4501 __ Ret(HasArgsInRegisters() ? 0 : 2); |
| 4502 } | 4502 } |
| 4503 } | 4503 } |
| 4504 | 4504 |
| 4505 | 4505 |
| 4506 void ArrayLengthStub::Generate(MacroAssembler* masm) { |
| 4507 Label miss; |
| 4508 Register receiver; |
| 4509 if (kind() == Code::KEYED_LOAD_IC) { |
| 4510 // ----------- S t a t e ------------- |
| 4511 // -- lr : return address |
| 4512 // -- r0 : key |
| 4513 // -- r1 : receiver |
| 4514 // ----------------------------------- |
| 4515 __ cmp(r0, Operand(masm->isolate()->factory()->length_symbol())); |
| 4516 __ b(ne, &miss); |
| 4517 receiver = r1; |
| 4518 } else { |
| 4519 ASSERT(kind() == Code::LOAD_IC); |
| 4520 // ----------- S t a t e ------------- |
| 4521 // -- r2 : name |
| 4522 // -- lr : return address |
| 4523 // -- r0 : receiver |
| 4524 // -- sp[0] : receiver |
| 4525 // ----------------------------------- |
| 4526 receiver = r0; |
| 4527 } |
| 4528 |
| 4529 StubCompiler::GenerateLoadArrayLength(masm, receiver, r3, &miss); |
| 4530 __ bind(&miss); |
| 4531 StubCompiler::GenerateLoadMiss(masm, kind()); |
| 4532 } |
| 4533 |
| 4534 |
| 4506 void StringLengthStub::Generate(MacroAssembler* masm) { | 4535 void StringLengthStub::Generate(MacroAssembler* masm) { |
| 4507 Label miss; | 4536 Label miss; |
| 4508 Register receiver; | 4537 Register receiver; |
| 4509 if (kind() == Code::KEYED_LOAD_IC) { | 4538 if (kind() == Code::KEYED_LOAD_IC) { |
| 4510 // ----------- S t a t e ------------- | 4539 // ----------- S t a t e ------------- |
| 4511 // -- lr : return address | 4540 // -- lr : return address |
| 4512 // -- r0 : key | 4541 // -- r0 : key |
| 4513 // -- r1 : receiver | 4542 // -- r1 : receiver |
| 4514 // ----------------------------------- | 4543 // ----------------------------------- |
| 4515 __ cmp(r0, Operand(masm->isolate()->factory()->length_symbol())); | 4544 __ cmp(r0, Operand(masm->isolate()->factory()->length_symbol())); |
| (...skipping 3266 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 7782 | 7811 |
| 7783 __ Pop(lr, r5, r1); | 7812 __ Pop(lr, r5, r1); |
| 7784 __ Ret(); | 7813 __ Ret(); |
| 7785 } | 7814 } |
| 7786 | 7815 |
| 7787 #undef __ | 7816 #undef __ |
| 7788 | 7817 |
| 7789 } } // namespace v8::internal | 7818 } } // namespace v8::internal |
| 7790 | 7819 |
| 7791 #endif // V8_TARGET_ARCH_ARM | 7820 #endif // V8_TARGET_ARCH_ARM |
| OLD | NEW |