Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(68)

Unified Diff: src/compiler/code-generator.cc

Issue 2682143002: [compiler] Pass deoptimization_kind through DeoptimizeParameters and FlagsContinuation (Closed)
Patch Set: fix Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/compiler/code-generator.h ('k') | src/compiler/common-operator.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/code-generator.cc
diff --git a/src/compiler/code-generator.cc b/src/compiler/code-generator.cc
index c1a54cad6e69b52ee5e5b00797dff09eceacaa46..d05953e8b4719d3e15284ccd398bd57b20307735 100644
--- a/src/compiler/code-generator.cc
+++ b/src/compiler/code-generator.cc
@@ -196,8 +196,7 @@ Handle<Code> CodeGenerator::GenerateCode() {
// Assemble all eager deoptimization exits.
for (DeoptimizationExit* exit : deoptimization_exits_) {
masm()->bind(exit->label());
- AssembleDeoptimizerCall(exit->deoptimization_id(), Deoptimizer::EAGER,
- exit->pos());
+ AssembleDeoptimizerCall(exit->deoptimization_id(), exit->pos());
}
// Ensure there is space for lazy deoptimization in the code.
@@ -672,6 +671,13 @@ DeoptimizationEntry const& CodeGenerator::GetDeoptimizationEntry(
return code()->GetDeoptimizationEntry(state_id);
}
+DeoptimizeKind CodeGenerator::GetDeoptimizationKind(
+ int deoptimization_id) const {
+ size_t const index = static_cast<size_t>(deoptimization_id);
+ DCHECK_LT(index, deoptimization_states_.size());
+ return deoptimization_states_[index]->kind();
+}
+
DeoptimizeReason CodeGenerator::GetDeoptimizationReason(
int deoptimization_id) const {
size_t const index = static_cast<size_t>(deoptimization_id);
@@ -836,7 +842,7 @@ int CodeGenerator::BuildTranslation(Instruction* instr, int pc_offset,
int deoptimization_id = static_cast<int>(deoptimization_states_.size());
deoptimization_states_.push_back(new (zone()) DeoptimizationState(
- descriptor->bailout_id(), translation.index(), pc_offset,
+ descriptor->bailout_id(), translation.index(), pc_offset, entry.kind(),
entry.reason()));
return deoptimization_id;
« no previous file with comments | « src/compiler/code-generator.h ('k') | src/compiler/common-operator.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698