Reviewers: Hannes Payer, danno, Benedikt Meurer, Michael Starzinger, Paul Lind, palfia, kisg,

Description:
Make offsets to inner allocated objects aligned in allocation folding.

Folded allocations marked for double alignment is not aligned if old dominator
size is used for offset to inner object.

TEST=mjsunit/big-array-literal on MIPS
BUG=

Please review this at https://codereview.chromium.org/103963005/

SVN Base: https://v8.googlecode.com/svn/branches/bleeding_edge

Affected files (+8, -1 lines):
  M src/hydrogen-instructions.cc


Index: src/hydrogen-instructions.cc
diff --git a/src/hydrogen-instructions.cc b/src/hydrogen-instructions.cc
index e7ad219964b3946b35e81dbd76011d7e8ff2133f..7f07ed59fffa02d02bbb4e2bcaa6cd9fb7220be7 100644
--- a/src/hydrogen-instructions.cc
+++ b/src/hydrogen-instructions.cc
@@ -3495,11 +3495,18 @@ void HAllocate::HandleSideEffectDominator(GVNFlag side_effect,
   dominator_allocate->clear_next_map_word_ = clear_next_map_word_;

   // After that replace the dominated allocate instruction.
+  HInstruction* inner_offset = HConstant::CreateAndInsertBefore(
+      zone,
+      context(),
+      dominator_size_constant,
+      Representation::None(),
+      this);
+
   HInstruction* dominated_allocate_instr =
       HInnerAllocatedObject::New(zone,
                                  context(),
                                  dominator_allocate,
-                                 dominator_size,
+                                 inner_offset,
                                  type());
   dominated_allocate_instr->InsertBefore(this);
   DeleteAndReplaceWith(dominated_allocate_instr);


--
--
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/groups/opt_out.

Reply via email to