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

Unified Diff: src/compiler/effect-control-linearizer.cc

Issue 2700143002: [turbofan] Don't report failed map check as failed instance migration. (Closed)
Patch Set: 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/effect-control-linearizer.cc
diff --git a/src/compiler/effect-control-linearizer.cc b/src/compiler/effect-control-linearizer.cc
index 1aa0ec6668c8ea5e228447ab3c3a082014acf9d5..36417ed7bacfff2f76e2c58f1b6844e8e01e090e 100644
--- a/src/compiler/effect-control-linearizer.cc
+++ b/src/compiler/effect-control-linearizer.cc
@@ -1102,16 +1102,14 @@ Node* EffectControlLinearizer::LowerCheckMaps(Node* node, Node* frame_state) {
// Perform the (deferred) instance migration.
__ Bind(&migrate);
{
- auto migration_failed = __ MakeLabel<2>();
- auto retry_check_maps = __ MakeLabel<2>();
-
// If map is not deprecated the migration attempt does not make sense.
Node* bitfield3 =
__ LoadField(AccessBuilder::ForMapBitField3(), value_map);
Node* if_not_deprecated = __ WordEqual(
__ Word32And(bitfield3, __ Int32Constant(Map::Deprecated::kMask)),
__ Int32Constant(0));
- __ GotoIf(if_not_deprecated, &migration_failed);
+ __ DeoptimizeIf(DeoptimizeReason::kWrongMap, if_not_deprecated,
+ frame_state);
Operator::Properties properties = Operator::kNoDeopt | Operator::kNoThrow;
Runtime::FunctionId id = Runtime::kTryMigrateInstance;
@@ -1122,15 +1120,8 @@ Node* EffectControlLinearizer::LowerCheckMaps(Node* node, Node* frame_state) {
__ ExternalConstant(ExternalReference(id, isolate())),
__ Int32Constant(1), __ NoContextConstant());
Node* check = ObjectIsSmi(result);
- __ GotoIf(check, &retry_check_maps);
- __ Goto(&migration_failed);
-
- __ Bind(&migration_failed);
- __ DeoptimizeIf(DeoptimizeReason::kInstanceMigrationFailed,
- __ Int32Constant(1), frame_state);
-
- __ Goto(&retry_check_maps);
- __ Bind(&retry_check_maps);
+ __ DeoptimizeIf(DeoptimizeReason::kInstanceMigrationFailed, check,
+ frame_state);
}
// Reload the current map of the {value}.
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698