| OLD | NEW |
| 1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 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 #ifndef V8_COMPILER_CODE_GENERATOR_H_ | 5 #ifndef V8_COMPILER_CODE_GENERATOR_H_ |
| 6 #define V8_COMPILER_CODE_GENERATOR_H_ | 6 #define V8_COMPILER_CODE_GENERATOR_H_ |
| 7 | 7 |
| 8 #include <deque> | |
| 9 | |
| 10 #include "src/compiler/gap-resolver.h" | 8 #include "src/compiler/gap-resolver.h" |
| 11 #include "src/compiler/instruction.h" | 9 #include "src/compiler/instruction.h" |
| 12 #include "src/deoptimizer.h" | 10 #include "src/deoptimizer.h" |
| 13 #include "src/macro-assembler.h" | 11 #include "src/macro-assembler.h" |
| 14 #include "src/safepoint-table.h" | 12 #include "src/safepoint-table.h" |
| 15 | 13 |
| 16 namespace v8 { | 14 namespace v8 { |
| 17 namespace internal { | 15 namespace internal { |
| 18 namespace compiler { | 16 namespace compiler { |
| 19 | 17 |
| 18 // Forward declarations. |
| 20 class Linkage; | 19 class Linkage; |
| 20 class OutOfLineCode; |
| 21 | 21 |
| 22 struct BranchInfo { | 22 struct BranchInfo { |
| 23 FlagsCondition condition; | 23 FlagsCondition condition; |
| 24 Label* true_label; | 24 Label* true_label; |
| 25 Label* false_label; | 25 Label* false_label; |
| 26 bool fallthru; | 26 bool fallthru; |
| 27 }; | 27 }; |
| 28 | 28 |
| 29 | 29 |
| 30 // Generates native code for a sequence of instructions. | 30 // Generates native code for a sequence of instructions. |
| (...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 122 : bailout_id_(bailout_id), | 122 : bailout_id_(bailout_id), |
| 123 translation_id_(translation_id), | 123 translation_id_(translation_id), |
| 124 pc_offset_(pc_offset) {} | 124 pc_offset_(pc_offset) {} |
| 125 | 125 |
| 126 private: | 126 private: |
| 127 BailoutId bailout_id_; | 127 BailoutId bailout_id_; |
| 128 int translation_id_; | 128 int translation_id_; |
| 129 int pc_offset_; | 129 int pc_offset_; |
| 130 }; | 130 }; |
| 131 | 131 |
| 132 friend class OutOfLineCode; |
| 133 |
| 132 Frame* const frame_; | 134 Frame* const frame_; |
| 133 Linkage* const linkage_; | 135 Linkage* const linkage_; |
| 134 InstructionSequence* const code_; | 136 InstructionSequence* const code_; |
| 135 CompilationInfo* const info_; | 137 CompilationInfo* const info_; |
| 136 Label* const labels_; | 138 Label* const labels_; |
| 137 BasicBlock::RpoNumber current_block_; | 139 BasicBlock::RpoNumber current_block_; |
| 138 SourcePosition current_source_position_; | 140 SourcePosition current_source_position_; |
| 139 MacroAssembler masm_; | 141 MacroAssembler masm_; |
| 140 GapResolver resolver_; | 142 GapResolver resolver_; |
| 141 SafepointTableBuilder safepoints_; | 143 SafepointTableBuilder safepoints_; |
| 142 ZoneDeque<DeoptimizationState*> deoptimization_states_; | 144 ZoneDeque<DeoptimizationState*> deoptimization_states_; |
| 143 ZoneDeque<Handle<Object> > deoptimization_literals_; | 145 ZoneDeque<Handle<Object> > deoptimization_literals_; |
| 144 TranslationBuffer translations_; | 146 TranslationBuffer translations_; |
| 145 int last_lazy_deopt_pc_; | 147 int last_lazy_deopt_pc_; |
| 148 OutOfLineCode* ools_; |
| 146 }; | 149 }; |
| 147 | 150 |
| 148 } // namespace compiler | 151 } // namespace compiler |
| 149 } // namespace internal | 152 } // namespace internal |
| 150 } // namespace v8 | 153 } // namespace v8 |
| 151 | 154 |
| 152 #endif // V8_COMPILER_CODE_GENERATOR_H | 155 #endif // V8_COMPILER_CODE_GENERATOR_H |
| OLD | NEW |