Revision: 21286
Author: [email protected]
Date: Tue May 13 09:56:35 2014 UTC
Log: Version 3.26.31.1 (merged r21196)
Fix index register assignment in LoadFieldByIndex for arm, arm64, and mips.
BUG=368243
LOG=N
[email protected]
Review URL: https://codereview.chromium.org/275103007
http://code.google.com/p/v8/source/detail?r=21286
Added:
/branches/3.26/test/mjsunit/regress/regress-368243.js
Modified:
/branches/3.26/src/arm/lithium-arm.cc
/branches/3.26/src/arm64/lithium-arm64.cc
/branches/3.26/src/mips/lithium-mips.cc
/branches/3.26/src/version.cc
=======================================
--- /dev/null
+++ /branches/3.26/test/mjsunit/regress/regress-368243.js Tue May 13
09:56:35 2014 UTC
@@ -0,0 +1,25 @@
+// Copyright 2014 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Flags: --allow-natives-syntax
+
+function foo(a, c){
+ for(var f in c) {
+ if ("object" === typeof c[f]) {
+ a[f] = c[f];
+ foo(a[f], c[f]);
+ }
+ }
+};
+
+c = {
+ "one" : { x : 1},
+ "two" : { x : 2},
+ "thr" : { x : 3, z : 4},
+};
+
+foo({}, c);
+foo({}, c);
+%OptimizeFunctionOnNextCall(foo);
+foo({}, c);
=======================================
--- /branches/3.26/src/arm/lithium-arm.cc Tue May 6 00:04:47 2014 UTC
+++ /branches/3.26/src/arm/lithium-arm.cc Tue May 13 09:56:35 2014 UTC
@@ -2556,7 +2556,7 @@
LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) {
LOperand* object = UseRegister(instr->object());
- LOperand* index = UseRegister(instr->index());
+ LOperand* index = UseTempRegister(instr->index());
LLoadFieldByIndex* load = new(zone()) LLoadFieldByIndex(object, index);
LInstruction* result = DefineSameAsFirst(load);
return AssignPointerMap(result);
=======================================
--- /branches/3.26/src/arm64/lithium-arm64.cc Tue May 6 00:04:47 2014 UTC
+++ /branches/3.26/src/arm64/lithium-arm64.cc Tue May 13 09:56:35 2014 UTC
@@ -2545,7 +2545,7 @@
LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) {
LOperand* object = UseRegisterAtStart(instr->object());
- LOperand* index = UseRegister(instr->index());
+ LOperand* index = UseRegisterAndClobber(instr->index());
LLoadFieldByIndex* load = new(zone()) LLoadFieldByIndex(object, index);
LInstruction* result = DefineSameAsFirst(load);
return AssignPointerMap(result);
=======================================
--- /branches/3.26/src/mips/lithium-mips.cc Tue May 6 00:04:47 2014 UTC
+++ /branches/3.26/src/mips/lithium-mips.cc Tue May 13 09:56:35 2014 UTC
@@ -2507,7 +2507,7 @@
LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) {
LOperand* object = UseRegister(instr->object());
- LOperand* index = UseRegister(instr->index());
+ LOperand* index = UseTempRegister(instr->index());
LLoadFieldByIndex* load = new(zone()) LLoadFieldByIndex(object, index);
LInstruction* result = DefineSameAsFirst(load);
return AssignPointerMap(result);
=======================================
--- /branches/3.26/src/version.cc Tue May 6 00:04:47 2014 UTC
+++ /branches/3.26/src/version.cc Tue May 13 09:56:35 2014 UTC
@@ -35,7 +35,7 @@
#define MAJOR_VERSION 3
#define MINOR_VERSION 26
#define BUILD_NUMBER 31
-#define PATCH_LEVEL 0
+#define PATCH_LEVEL 1
// 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.