| 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 7473 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 7484 Label no_info, switch_ready; | 7484 Label no_info, switch_ready; |
| 7485 // Get the elements kind and case on that. | 7485 // Get the elements kind and case on that. |
| 7486 __ LoadRoot(at, Heap::kUndefinedValueRootIndex); | 7486 __ LoadRoot(at, Heap::kUndefinedValueRootIndex); |
| 7487 __ Branch(&no_info, eq, a2, Operand(at)); | 7487 __ Branch(&no_info, eq, a2, Operand(at)); |
| 7488 __ lw(a3, FieldMemOperand(a2, Cell::kValueOffset)); | 7488 __ lw(a3, FieldMemOperand(a2, Cell::kValueOffset)); |
| 7489 | 7489 |
| 7490 // The type cell may have undefined in its value. | 7490 // The type cell may have undefined in its value. |
| 7491 __ LoadRoot(at, Heap::kUndefinedValueRootIndex); | 7491 __ LoadRoot(at, Heap::kUndefinedValueRootIndex); |
| 7492 __ Branch(&no_info, eq, a3, Operand(at)); | 7492 __ Branch(&no_info, eq, a3, Operand(at)); |
| 7493 | 7493 |
| 7494 // We should have an allocation site object | 7494 // The type cell has either an AllocationSite or a JSFunction. |
| 7495 if (FLAG_debug_code) { | 7495 __ lw(t0, FieldMemOperand(a3, 0)); |
| 7496 __ push(a3); | 7496 __ LoadRoot(at, Heap::kAllocationSiteMapRootIndex); |
| 7497 __ sw(a3, FieldMemOperand(a3, 0)); | 7497 __ Branch(&no_info, ne, t0, Operand(at)); |
| 7498 __ LoadRoot(at, Heap::kAllocationSiteMapRootIndex); | |
| 7499 __ Assert(eq, "Expected AllocationSite object in register a3", | |
| 7500 a3, Operand(at)); | |
| 7501 } | |
| 7502 | 7498 |
| 7503 __ lw(a3, FieldMemOperand(a3, AllocationSite::kPayloadOffset)); | 7499 __ lw(a3, FieldMemOperand(a3, AllocationSite::kPayloadOffset)); |
| 7504 __ SmiUntag(a3); | 7500 __ SmiUntag(a3); |
| 7505 __ jmp(&switch_ready); | 7501 __ jmp(&switch_ready); |
| 7506 __ bind(&no_info); | 7502 __ bind(&no_info); |
| 7507 __ li(a3, Operand(GetInitialFastElementsKind())); | 7503 __ li(a3, Operand(GetInitialFastElementsKind())); |
| 7508 __ bind(&switch_ready); | 7504 __ bind(&switch_ready); |
| 7509 | 7505 |
| 7510 if (argument_count_ == ANY) { | 7506 if (argument_count_ == ANY) { |
| 7511 Label not_zero_case, not_one_case; | 7507 Label not_zero_case, not_one_case; |
| (...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 7612 __ bind(&fast_elements_case); | 7608 __ bind(&fast_elements_case); |
| 7613 GenerateCase(masm, FAST_ELEMENTS); | 7609 GenerateCase(masm, FAST_ELEMENTS); |
| 7614 } | 7610 } |
| 7615 | 7611 |
| 7616 | 7612 |
| 7617 #undef __ | 7613 #undef __ |
| 7618 | 7614 |
| 7619 } } // namespace v8::internal | 7615 } } // namespace v8::internal |
| 7620 | 7616 |
| 7621 #endif // V8_TARGET_ARCH_MIPS | 7617 #endif // V8_TARGET_ARCH_MIPS |
| OLD | NEW |