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

Unified Diff: test/mjsunit/compiler/load-elimination.js

Issue 155723005: A64: Synchronize with r19001. (Closed) Base URL: https://v8.googlecode.com/svn/branches/experimental/a64
Patch Set: Created 6 years, 10 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 | « test/mjsunit/compiler/escape-analysis-arguments.js ('k') | test/mjsunit/error-tostring-omit.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/mjsunit/compiler/load-elimination.js
diff --git a/test/mjsunit/compiler/load-elimination.js b/test/mjsunit/compiler/load-elimination.js
index e6a82451821288e5a4665764e6e8b88b7387f72f..9bf8564308218e05973accbe1015a00eb46eae5d 100644
--- a/test/mjsunit/compiler/load-elimination.js
+++ b/test/mjsunit/compiler/load-elimination.js
@@ -43,6 +43,26 @@ function test_load() {
return a.x + a.x + a.x + a.x;
}
+
+function test_load_from_different_contexts() {
+ var r = 1;
+ this.f = function() {
+ var fr = r;
+ this.g = function(flag) {
+ var gr;
+ if (flag) {
+ gr = r;
+ } else {
+ gr = r;
+ }
+ return gr + r + fr;
+ };
+ };
+ this.f();
+ return this.g(true);
+}
+
+
function test_store_load() {
var a = new B(1, 2);
a.x = 4;
@@ -128,6 +148,7 @@ function test(x, f) {
}
test(4, test_load);
+test(3, new test_load_from_different_contexts().g);
test(22, test_store_load);
test(8, test_nonaliasing_store1);
test(5, test_transitioning_store1);
« no previous file with comments | « test/mjsunit/compiler/escape-analysis-arguments.js ('k') | test/mjsunit/error-tostring-omit.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698