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

Unified Diff: src/full-codegen/full-codegen.cc

Issue 1638353002: [fullcodegen] Cleanup MustCreateObjectLiteralWithRuntime. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Rebased. Created 4 years, 11 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/ast/ast.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/full-codegen/full-codegen.cc
diff --git a/src/full-codegen/full-codegen.cc b/src/full-codegen/full-codegen.cc
index 2edb9c6bd94bbce59600ba32001710dedb5cce0d..0e3dba66eb5fd71893deb79b2143716a13bc56a0 100644
--- a/src/full-codegen/full-codegen.cc
+++ b/src/full-codegen/full-codegen.cc
@@ -143,13 +143,11 @@ int FullCodeGenerator::NewHandlerTableEntry() {
bool FullCodeGenerator::MustCreateObjectLiteralWithRuntime(
ObjectLiteral* expr) const {
- int literal_flags = expr->ComputeFlags();
// FastCloneShallowObjectStub doesn't copy elements, and object literals don't
// support copy-on-write (COW) elements for now.
// TODO(mvstanton): make object literals support COW elements.
- return masm()->serializer_enabled() ||
- (literal_flags & ObjectLiteral::kShallowProperties) == 0 ||
- (literal_flags & ObjectLiteral::kFastElements) == 0 ||
+ return masm()->serializer_enabled() || !expr->fast_elements() ||
+ !expr->has_shallow_properties() ||
expr->properties_count() >
FastCloneShallowObjectStub::kMaximumClonedProperties;
}
« no previous file with comments | « src/ast/ast.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698