OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved.7 | 1 // Copyright 2012 the V8 project authors. All rights reserved.7 |
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 16 matching lines...) Expand all Loading... |
27 | 27 |
28 #include "src/crankshaft/mips/lithium-codegen-mips.h" | 28 #include "src/crankshaft/mips/lithium-codegen-mips.h" |
29 | 29 |
30 #include "src/base/bits.h" | 30 #include "src/base/bits.h" |
31 #include "src/code-factory.h" | 31 #include "src/code-factory.h" |
32 #include "src/code-stubs.h" | 32 #include "src/code-stubs.h" |
33 #include "src/crankshaft/hydrogen-osr.h" | 33 #include "src/crankshaft/hydrogen-osr.h" |
34 #include "src/crankshaft/mips/lithium-gap-resolver-mips.h" | 34 #include "src/crankshaft/mips/lithium-gap-resolver-mips.h" |
35 #include "src/ic/ic.h" | 35 #include "src/ic/ic.h" |
36 #include "src/ic/stub-cache.h" | 36 #include "src/ic/stub-cache.h" |
37 #include "src/profiler/cpu-profiler.h" | |
38 | |
39 | 37 |
40 namespace v8 { | 38 namespace v8 { |
41 namespace internal { | 39 namespace internal { |
42 | 40 |
43 | 41 |
44 class SafepointGenerator final : public CallWrapper { | 42 class SafepointGenerator final : public CallWrapper { |
45 public: | 43 public: |
46 SafepointGenerator(LCodeGen* codegen, | 44 SafepointGenerator(LCodeGen* codegen, |
47 LPointerMap* pointers, | 45 LPointerMap* pointers, |
48 Safepoint::DeoptMode mode) | 46 Safepoint::DeoptMode mode) |
(...skipping 745 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
794 // restore caller doubles. | 792 // restore caller doubles. |
795 if (condition == al && frame_is_built_ && | 793 if (condition == al && frame_is_built_ && |
796 !info()->saves_caller_doubles()) { | 794 !info()->saves_caller_doubles()) { |
797 DeoptComment(deopt_info); | 795 DeoptComment(deopt_info); |
798 __ Call(entry, RelocInfo::RUNTIME_ENTRY, condition, src1, src2); | 796 __ Call(entry, RelocInfo::RUNTIME_ENTRY, condition, src1, src2); |
799 } else { | 797 } else { |
800 Deoptimizer::JumpTableEntry table_entry(entry, deopt_info, bailout_type, | 798 Deoptimizer::JumpTableEntry table_entry(entry, deopt_info, bailout_type, |
801 !frame_is_built_); | 799 !frame_is_built_); |
802 // We often have several deopts to the same entry, reuse the last | 800 // We often have several deopts to the same entry, reuse the last |
803 // jump entry if this is the case. | 801 // jump entry if this is the case. |
804 if (FLAG_trace_deopt || isolate()->cpu_profiler()->is_profiling() || | 802 if (FLAG_trace_deopt || isolate()->is_profiling() || |
805 jump_table_.is_empty() || | 803 jump_table_.is_empty() || |
806 !table_entry.IsEquivalentTo(jump_table_.last())) { | 804 !table_entry.IsEquivalentTo(jump_table_.last())) { |
807 jump_table_.Add(table_entry, zone()); | 805 jump_table_.Add(table_entry, zone()); |
808 } | 806 } |
809 __ Branch(&jump_table_.last().label, condition, src1, src2); | 807 __ Branch(&jump_table_.last().label, condition, src1, src2); |
810 } | 808 } |
811 } | 809 } |
812 | 810 |
813 | 811 |
814 void LCodeGen::DeoptimizeIf(Condition condition, LInstruction* instr, | 812 void LCodeGen::DeoptimizeIf(Condition condition, LInstruction* instr, |
(...skipping 4743 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5558 __ lw(result, FieldMemOperand(scratch, | 5556 __ lw(result, FieldMemOperand(scratch, |
5559 FixedArray::kHeaderSize - kPointerSize)); | 5557 FixedArray::kHeaderSize - kPointerSize)); |
5560 __ bind(deferred->exit()); | 5558 __ bind(deferred->exit()); |
5561 __ bind(&done); | 5559 __ bind(&done); |
5562 } | 5560 } |
5563 | 5561 |
5564 #undef __ | 5562 #undef __ |
5565 | 5563 |
5566 } // namespace internal | 5564 } // namespace internal |
5567 } // namespace v8 | 5565 } // namespace v8 |
OLD | NEW |