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 859 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
870 // Other register combinations are generated as and when they are needed, | 870 // Other register combinations are generated as and when they are needed, |
871 // so it is unsafe to call them from stubs (we can't generate a stub while | 871 // so it is unsafe to call them from stubs (we can't generate a stub while |
872 // we are generating a stub). | 872 // we are generating a stub). |
873 return false; | 873 return false; |
874 } | 874 } |
875 | 875 |
876 | 876 |
877 void WriteInt32ToHeapNumberStub::GenerateFixedRegStubsAheadOfTime() { | 877 void WriteInt32ToHeapNumberStub::GenerateFixedRegStubsAheadOfTime() { |
878 WriteInt32ToHeapNumberStub stub1(r1, r0, r2); | 878 WriteInt32ToHeapNumberStub stub1(r1, r0, r2); |
879 WriteInt32ToHeapNumberStub stub2(r2, r0, r3); | 879 WriteInt32ToHeapNumberStub stub2(r2, r0, r3); |
880 Handle<Code> code1 = stub1.GetCode(); | 880 Handle<Code> code1 = stub1.GetCode()->set_is_pregenerated(true); |
881 Handle<Code> code2 = stub2.GetCode(); | 881 Handle<Code> code2 = stub2.GetCode()->set_is_pregenerated(true); |
882 } | 882 } |
883 | 883 |
884 | 884 |
885 // See comment for class. | 885 // See comment for class. |
886 void WriteInt32ToHeapNumberStub::Generate(MacroAssembler* masm) { | 886 void WriteInt32ToHeapNumberStub::Generate(MacroAssembler* masm) { |
887 Label max_negative_int; | 887 Label max_negative_int; |
888 // the_int_ has the answer which is a signed int32 but not a Smi. | 888 // the_int_ has the answer which is a signed int32 but not a Smi. |
889 // We test for the special value that has a different exponent. This test | 889 // We test for the special value that has a different exponent. This test |
890 // has the neat side effect of setting the flags according to the sign. | 890 // has the neat side effect of setting the flags according to the sign. |
891 STATIC_ASSERT(HeapNumber::kSignMask == 0x80000000u); | 891 STATIC_ASSERT(HeapNumber::kSignMask == 0x80000000u); |
(...skipping 2514 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3406 | 3406 |
3407 void CodeStub::GenerateStubsAheadOfTime() { | 3407 void CodeStub::GenerateStubsAheadOfTime() { |
3408 WriteInt32ToHeapNumberStub::GenerateFixedRegStubsAheadOfTime(); | 3408 WriteInt32ToHeapNumberStub::GenerateFixedRegStubsAheadOfTime(); |
3409 StoreBufferOverflowStub::GenerateFixedRegStubsAheadOfTime(); | 3409 StoreBufferOverflowStub::GenerateFixedRegStubsAheadOfTime(); |
3410 RecordWriteStub::GenerateFixedRegStubsAheadOfTime(); | 3410 RecordWriteStub::GenerateFixedRegStubsAheadOfTime(); |
3411 } | 3411 } |
3412 | 3412 |
3413 | 3413 |
3414 void CodeStub::GenerateFPStubs() { | 3414 void CodeStub::GenerateFPStubs() { |
3415 CEntryStub save_doubles(1, kSaveFPRegs); | 3415 CEntryStub save_doubles(1, kSaveFPRegs); |
3416 Handle<Code> code = save_doubles.GetCode(); | 3416 Handle<Code> code = save_doubles.GetCode()->set_is_pregenerated(true); |
3417 code->GetIsolate()->set_fp_stubs_generated(true); | 3417 code->GetIsolate()->set_fp_stubs_generated(true); |
3418 } | 3418 } |
3419 | 3419 |
3420 | 3420 |
3421 void CEntryStub::GenerateThrowTOS(MacroAssembler* masm) { | 3421 void CEntryStub::GenerateThrowTOS(MacroAssembler* masm) { |
3422 __ Throw(r0); | 3422 __ Throw(r0); |
3423 } | 3423 } |
3424 | 3424 |
3425 | 3425 |
3426 void CEntryStub::GenerateThrowUncatchable(MacroAssembler* masm, | 3426 void CEntryStub::GenerateThrowUncatchable(MacroAssembler* masm, |
(...skipping 3443 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6870 save_fp_regs_mode_ == kDontSaveFPRegs) { | 6870 save_fp_regs_mode_ == kDontSaveFPRegs) { |
6871 return true; | 6871 return true; |
6872 } | 6872 } |
6873 } | 6873 } |
6874 return false; | 6874 return false; |
6875 } | 6875 } |
6876 | 6876 |
6877 | 6877 |
6878 void StoreBufferOverflowStub::GenerateFixedRegStubsAheadOfTime() { | 6878 void StoreBufferOverflowStub::GenerateFixedRegStubsAheadOfTime() { |
6879 StoreBufferOverflowStub stub1(kDontSaveFPRegs); | 6879 StoreBufferOverflowStub stub1(kDontSaveFPRegs); |
6880 stub1.GetCode(); | 6880 stub1.GetCode()->set_is_pregenerated(true); |
6881 StoreBufferOverflowStub stub2(kSaveFPRegs); | 6881 StoreBufferOverflowStub stub2(kSaveFPRegs); |
6882 stub2.GetCode(); | 6882 stub2.GetCode()->set_is_pregenerated(true); |
6883 } | 6883 } |
6884 | 6884 |
6885 | 6885 |
6886 void RecordWriteStub::GenerateFixedRegStubsAheadOfTime() { | 6886 void RecordWriteStub::GenerateFixedRegStubsAheadOfTime() { |
6887 for (AheadOfTimeWriteBarrierStubList* entry = kAheadOfTime; | 6887 for (AheadOfTimeWriteBarrierStubList* entry = kAheadOfTime; |
6888 !entry->object.is(no_reg); | 6888 !entry->object.is(no_reg); |
6889 entry++) { | 6889 entry++) { |
6890 RecordWriteStub stub(entry->object, | 6890 RecordWriteStub stub(entry->object, |
6891 entry->value, | 6891 entry->value, |
6892 entry->address, | 6892 entry->address, |
6893 entry->action, | 6893 entry->action, |
6894 kDontSaveFPRegs); | 6894 kDontSaveFPRegs); |
6895 stub.GetCode(); | 6895 stub.GetCode()->set_is_pregenerated(true); |
6896 } | 6896 } |
6897 } | 6897 } |
6898 | 6898 |
6899 | 6899 |
6900 // Takes the input in 3 registers: address_ value_ and object_. A pointer to | 6900 // Takes the input in 3 registers: address_ value_ and object_. A pointer to |
6901 // the value has just been written into the object, now this stub makes sure | 6901 // the value has just been written into the object, now this stub makes sure |
6902 // we keep the GC informed. The word in the object where the value has been | 6902 // we keep the GC informed. The word in the object where the value has been |
6903 // written is in the address register. | 6903 // written is in the address register. |
6904 void RecordWriteStub::Generate(MacroAssembler* masm) { | 6904 void RecordWriteStub::Generate(MacroAssembler* masm) { |
6905 Label skip_to_incremental_noncompacting; | 6905 Label skip_to_incremental_noncompacting; |
(...skipping 180 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7086 | 7086 |
7087 // Fall through when we need to inform the incremental marker. | 7087 // Fall through when we need to inform the incremental marker. |
7088 } | 7088 } |
7089 | 7089 |
7090 | 7090 |
7091 #undef __ | 7091 #undef __ |
7092 | 7092 |
7093 } } // namespace v8::internal | 7093 } } // namespace v8::internal |
7094 | 7094 |
7095 #endif // V8_TARGET_ARCH_ARM | 7095 #endif // V8_TARGET_ARCH_ARM |
OLD | NEW |