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

Unified Diff: test/mjsunit/regress/regress-map-invalidation-2.js

Issue 22807003: Fix regressions triggered by map invalidation during graph creation. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 4 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
Index: test/mjsunit/regress/regress-map-invalidation-2.js
diff --git a/test/mjsunit/regress/regress-119429.js b/test/mjsunit/regress/regress-map-invalidation-2.js
similarity index 84%
copy from test/mjsunit/regress/regress-119429.js
copy to test/mjsunit/regress/regress-map-invalidation-2.js
index a87648754a43e8d74b98b642495ba4e40f1551e9..c6d24cc4801cbe8482896e96913719c3b806f9de 100644
--- a/test/mjsunit/regress/regress-119429.js
+++ b/test/mjsunit/regress/regress-map-invalidation-2.js
@@ -27,11 +27,23 @@
// Flags: --allow-natives-syntax
-var d = 0;
-function recurse() {
- if (++d == 25135) { // A magic number just below stack overflow on ia32
- %DebugBreak();
+var c = { x: 2, y: 1 };
+
+function g() {
+ var outer = { foo: 1 };
+ function f() {
+ var n = outer.foo;
+ for (var i = 0; i < 100000; i++) {
+ n += c.x + outer.foo;
+ }
+ var o2 = [{ x: 1.5, y: 1 }];
+ return o2;
}
- recurse();
+ return f;
}
-assertThrows(function() { recurse();} );
+
+var fun = g();
+fun();
+assertOptimized(fun);
+fun();
+

Powered by Google App Engine
This is Rietveld 408576698