Chromium Code Reviews| 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 6698 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 6709 | 6709 |
| 6710 ASSERT(GetCondition() == eq); | 6710 ASSERT(GetCondition() == eq); |
| 6711 __ sub(r0, r0, Operand(r1)); | 6711 __ sub(r0, r0, Operand(r1)); |
| 6712 __ Ret(); | 6712 __ Ret(); |
| 6713 | 6713 |
| 6714 __ bind(&miss); | 6714 __ bind(&miss); |
| 6715 GenerateMiss(masm); | 6715 GenerateMiss(masm); |
| 6716 } | 6716 } |
| 6717 | 6717 |
| 6718 | 6718 |
| 6719 void ICCompareStub::GenerateKnownObjects(MacroAssembler* masm) { | |
| 6720 Label miss; | |
| 6721 __ and_(r2, r1, Operand(r0)); | |
| 6722 __ JumpIfSmi(r2, &miss); | |
| 6723 __ ldr(r2, FieldMemOperand(r0, HeapObject::kMapOffset)); | |
| 6724 __ ldr(r3, FieldMemOperand(r1, HeapObject::kMapOffset)); | |
| 6725 __ cmp(r2, Operand(known_map_)); | |
| 6726 __ b(ne, &miss); | |
| 6727 __ cmp(r3, Operand(known_map_)); | |
| 6728 __ b(ne, &miss); | |
| 6729 | |
| 6730 __ sub(r0, r0, Operand(r1)); | |
| 6731 __ Ret(); | |
| 6732 | |
| 6733 __ bind(&miss); | |
| 6734 GenerateMiss(masm); | |
| 6735 } | |
| 6736 | |
| 6737 | |
| 6738 | |
| 6719 void ICCompareStub::GenerateMiss(MacroAssembler* masm) { | 6739 void ICCompareStub::GenerateMiss(MacroAssembler* masm) { |
| 6720 __ Push(r1, r0); | 6740 __ Push(r1, r0); |
|
Kevin Millikin (Chromium)
2011/12/09 09:10:31
You could move this (and the corresponding pops) t
Rico
2011/12/09 09:28:31
Done.
| |
| 6721 __ push(lr); | 6741 __ push(lr); |
| 6722 | 6742 |
| 6723 // Call the runtime system in a fresh internal frame. | 6743 // Call the runtime system in a fresh internal frame. |
| 6724 ExternalReference miss = | 6744 ExternalReference miss = |
| 6725 ExternalReference(IC_Utility(IC::kCompareIC_Miss), masm->isolate()); | 6745 ExternalReference(IC_Utility(IC::kCompareIC_Miss), masm->isolate()); |
| 6726 { | 6746 { |
| 6727 FrameScope scope(masm, StackFrame::INTERNAL); | 6747 FrameScope scope(masm, StackFrame::INTERNAL); |
| 6728 __ Push(r1, r0); | 6748 __ Push(r1, r0); |
| 6729 __ mov(ip, Operand(Smi::FromInt(op_))); | 6749 __ mov(ip, Operand(Smi::FromInt(op_))); |
| 6730 __ push(ip); | 6750 __ push(ip); |
| (...skipping 605 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 7336 __ StoreNumberToDoubleElements(r0, r3, r1, r5, r6, r7, r9, r10, | 7356 __ StoreNumberToDoubleElements(r0, r3, r1, r5, r6, r7, r9, r10, |
| 7337 &slow_elements); | 7357 &slow_elements); |
| 7338 __ Ret(); | 7358 __ Ret(); |
| 7339 } | 7359 } |
| 7340 | 7360 |
| 7341 #undef __ | 7361 #undef __ |
| 7342 | 7362 |
| 7343 } } // namespace v8::internal | 7363 } } // namespace v8::internal |
| 7344 | 7364 |
| 7345 #endif // V8_TARGET_ARCH_ARM | 7365 #endif // V8_TARGET_ARCH_ARM |
| OLD | NEW |