diff --git a/src/objects.cc b/src/objects.cc index 627d371142..c874ee3c08 100644 --- a/src/objects.cc +++ b/src/objects.cc @@ -2784,7 +2784,6 @@ Handle Map::GeneralizeRepresentation(Handle old_map, Handle new_map = split_map; for (; descriptor < descriptors; descriptor++) { new_map = Map::CopyInstallDescriptors(new_map, descriptor, new_descriptors); - new_map->set_migration_target(true); } new_map->set_owns_descriptors(true); @@ -3875,6 +3874,7 @@ void JSObject::MigrateInstance(Handle object) { Handle original_map(object->map()); GeneralizeFieldRepresentation( object, 0, Representation::None(), ALLOW_AS_CONSTANT); + object->map()->set_migration_target(true); if (FLAG_trace_migration) { object->PrintInstanceMigration(stdout, *original_map, object->map()); }