summaryrefslogtreecommitdiff
path: root/deps/v8/src/compiler/code-generator.h
diff options
context:
space:
mode:
Diffstat (limited to 'deps/v8/src/compiler/code-generator.h')
-rw-r--r--deps/v8/src/compiler/code-generator.h18
1 files changed, 17 insertions, 1 deletions
diff --git a/deps/v8/src/compiler/code-generator.h b/deps/v8/src/compiler/code-generator.h
index 747bad2e22..658394b321 100644
--- a/deps/v8/src/compiler/code-generator.h
+++ b/deps/v8/src/compiler/code-generator.h
@@ -38,7 +38,7 @@ class CodeGenerator FINAL : public GapResolver::Assembler {
InstructionSequence* code() const { return code_; }
Frame* frame() const { return frame_; }
- Isolate* isolate() const { return zone()->isolate(); }
+ Isolate* isolate() const { return info_->isolate(); }
Linkage* linkage() const { return linkage_; }
Label* GetLabel(BasicBlock::RpoNumber rpo) { return &labels_[rpo.ToSize()]; }
@@ -71,6 +71,8 @@ class CodeGenerator FINAL : public GapResolver::Assembler {
void AssembleArchJump(BasicBlock::RpoNumber target);
void AssembleArchBranch(Instruction* instr, BranchInfo* branch);
void AssembleArchBoolean(Instruction* instr, FlagsCondition condition);
+ void AssembleArchLookupSwitch(Instruction* instr);
+ void AssembleArchTableSwitch(Instruction* instr);
void AssembleDeoptimizerCall(int deoptimization_id);
@@ -92,6 +94,18 @@ class CodeGenerator FINAL : public GapResolver::Assembler {
InstructionOperand* destination) FINAL;
// ===========================================================================
+ // =================== Jump table construction methods. ======================
+ // ===========================================================================
+
+ class JumpTable;
+ // Adds a jump table that is emitted after the actual code. Returns label
+ // pointing to the beginning of the table. {targets} is assumed to be static
+ // or zone allocated.
+ Label* AddJumpTable(Label** targets, size_t target_count);
+ // Emits a jump table.
+ void AssembleJumpTable(Label** targets, size_t target_count);
+
+ // ===========================================================================
// Deoptimization table construction
void AddSafepointAndDeopt(Instruction* instr);
void PopulateDeoptimizationData(Handle<Code> code);
@@ -145,7 +159,9 @@ class CodeGenerator FINAL : public GapResolver::Assembler {
ZoneDeque<Handle<Object> > deoptimization_literals_;
TranslationBuffer translations_;
int last_lazy_deopt_pc_;
+ JumpTable* jump_tables_;
OutOfLineCode* ools_;
+ int osr_pc_offset_;
};
} // namespace compiler