Reviewers: jochen,
Description:
Merged r20262 into 3.23 branch.
Always initialize elements pointer in fast literals.
[email protected]
BUG=355586
Please review this at https://codereview.chromium.org/219213002/
SVN Base: https://v8.googlecode.com/svn/branches/3.23
Affected files (+10, -1 lines):
M src/hydrogen.cc
M src/version.cc
Index: src/hydrogen.cc
diff --git a/src/hydrogen.cc b/src/hydrogen.cc
index
c40d2e77ffcf504195330a4315941cff4a16f4c3..80f0e311a34747b4a3c3a3ae90bb2dc49672fee1
100644
--- a/src/hydrogen.cc
+++ b/src/hydrogen.cc
@@ -9362,6 +9362,15 @@ HInstruction*
HOptimizedGraphBuilder::BuildFastLiteral(
HInstruction* object = Add<HAllocate>(object_size_constant, type,
pretenure_flag, instance_type, site_context->current());
+ // If allocation folding reaches Page::kMaxRegularHeapObjectSize the
+ // elements array may not get folded into the object. Hence, we set the
+ // elements pointer to empty fixed array and let store elimination remove
+ // this store in the folding case.
+ HConstant* empty_fixed_array = Add<HConstant>(
+ isolate()->factory()->empty_fixed_array());
+ Add<HStoreNamedField>(object, HObjectAccess::ForElementsPointer(),
+ empty_fixed_array);
+
BuildEmitObjectHeader(boilerplate_object, object);
Handle<FixedArrayBase> elements(boilerplate_object->elements());
Index: src/version.cc
diff --git a/src/version.cc b/src/version.cc
index
142fb9a27a5fe4e53187c2273ecf7d93a2efe65d..619b15dd6552324b2f2a9744d92465a885f38a2e
100644
--- a/src/version.cc
+++ b/src/version.cc
@@ -35,7 +35,7 @@
#define MAJOR_VERSION 3
#define MINOR_VERSION 23
#define BUILD_NUMBER 17
-#define PATCH_LEVEL 29
+#define PATCH_LEVEL 30
// Use 1 for candidates and 0 otherwise.
// (Boolean macro values are not supported by all preprocessors.)
#define IS_CANDIDATE_VERSION 0
--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
---
You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.