| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "src/crankshaft/mips64/lithium-codegen-mips64.h" | 5 #include "src/crankshaft/mips64/lithium-codegen-mips64.h" |
| 6 | 6 |
| 7 #include "src/code-factory.h" | 7 #include "src/code-factory.h" |
| 8 #include "src/code-stubs.h" | 8 #include "src/code-stubs.h" |
| 9 #include "src/crankshaft/hydrogen-osr.h" | 9 #include "src/crankshaft/hydrogen-osr.h" |
| 10 #include "src/crankshaft/mips64/lithium-gap-resolver-mips64.h" | 10 #include "src/crankshaft/mips64/lithium-gap-resolver-mips64.h" |
| 11 #include "src/ic/ic.h" | 11 #include "src/ic/ic.h" |
| 12 #include "src/ic/stub-cache.h" | 12 #include "src/ic/stub-cache.h" |
| 13 #include "src/profiler/cpu-profiler.h" | |
| 14 | 13 |
| 15 namespace v8 { | 14 namespace v8 { |
| 16 namespace internal { | 15 namespace internal { |
| 17 | 16 |
| 18 | 17 |
| 19 class SafepointGenerator final : public CallWrapper { | 18 class SafepointGenerator final : public CallWrapper { |
| 20 public: | 19 public: |
| 21 SafepointGenerator(LCodeGen* codegen, | 20 SafepointGenerator(LCodeGen* codegen, |
| 22 LPointerMap* pointers, | 21 LPointerMap* pointers, |
| 23 Safepoint::DeoptMode mode) | 22 Safepoint::DeoptMode mode) |
| (...skipping 758 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 782 if (condition == al && frame_is_built_ && | 781 if (condition == al && frame_is_built_ && |
| 783 !info()->saves_caller_doubles()) { | 782 !info()->saves_caller_doubles()) { |
| 784 DeoptComment(deopt_info); | 783 DeoptComment(deopt_info); |
| 785 __ Call(entry, RelocInfo::RUNTIME_ENTRY, condition, src1, src2); | 784 __ Call(entry, RelocInfo::RUNTIME_ENTRY, condition, src1, src2); |
| 786 } else { | 785 } else { |
| 787 Deoptimizer::JumpTableEntry* table_entry = | 786 Deoptimizer::JumpTableEntry* table_entry = |
| 788 new (zone()) Deoptimizer::JumpTableEntry( | 787 new (zone()) Deoptimizer::JumpTableEntry( |
| 789 entry, deopt_info, bailout_type, !frame_is_built_); | 788 entry, deopt_info, bailout_type, !frame_is_built_); |
| 790 // We often have several deopts to the same entry, reuse the last | 789 // We often have several deopts to the same entry, reuse the last |
| 791 // jump entry if this is the case. | 790 // jump entry if this is the case. |
| 792 if (FLAG_trace_deopt || isolate()->cpu_profiler()->is_profiling() || | 791 if (FLAG_trace_deopt || isolate()->is_profiling() || |
| 793 jump_table_.is_empty() || | 792 jump_table_.is_empty() || |
| 794 !table_entry->IsEquivalentTo(*jump_table_.last())) { | 793 !table_entry->IsEquivalentTo(*jump_table_.last())) { |
| 795 jump_table_.Add(table_entry, zone()); | 794 jump_table_.Add(table_entry, zone()); |
| 796 } | 795 } |
| 797 __ Branch(&jump_table_.last()->label, condition, src1, src2); | 796 __ Branch(&jump_table_.last()->label, condition, src1, src2); |
| 798 } | 797 } |
| 799 } | 798 } |
| 800 | 799 |
| 801 | 800 |
| 802 void LCodeGen::DeoptimizeIf(Condition condition, LInstruction* instr, | 801 void LCodeGen::DeoptimizeIf(Condition condition, LInstruction* instr, |
| (...skipping 4958 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5761 __ ld(result, FieldMemOperand(scratch, | 5760 __ ld(result, FieldMemOperand(scratch, |
| 5762 FixedArray::kHeaderSize - kPointerSize)); | 5761 FixedArray::kHeaderSize - kPointerSize)); |
| 5763 __ bind(deferred->exit()); | 5762 __ bind(deferred->exit()); |
| 5764 __ bind(&done); | 5763 __ bind(&done); |
| 5765 } | 5764 } |
| 5766 | 5765 |
| 5767 #undef __ | 5766 #undef __ |
| 5768 | 5767 |
| 5769 } // namespace internal | 5768 } // namespace internal |
| 5770 } // namespace v8 | 5769 } // namespace v8 |
| OLD | NEW |