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

Unified Diff: test/mjsunit/compiler/osr-big.js

Issue 16381006: Change PC for OSR entries to point to something more sensible (i.e. the first UnknownOsrValue), rem… (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Add --always-osr flag. Created 7 years, 6 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 | « src/x64/lithium-x64.cc ('k') | test/mjsunit/compiler/osr-nested.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/mjsunit/compiler/osr-big.js
diff --git a/test/mjsunit/regress/regress-2499.js b/test/mjsunit/compiler/osr-big.js
similarity index 85%
copy from test/mjsunit/regress/regress-2499.js
copy to test/mjsunit/compiler/osr-big.js
index 52aad874db6fcdc89f5ee1ae4db45304e64b0e77..ed71744b78e3c51aca7b62fcbf4b4c04a6d6904a 100644
--- a/test/mjsunit/regress/regress-2499.js
+++ b/test/mjsunit/compiler/osr-big.js
@@ -25,16 +25,21 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-// Flags: --allow-natives-syntax
+// Flags: --use-osr
-function foo(word, nBits) {
- return (word[1] >>> nBits) | (word[0] << (32 - nBits));
+function f(x) {
+ var sum = 0;
+ var outer = 1000000;
+ var a = 1, b = 2, c = 3, d = 4, e = 5;
+ while (outer > 0) {
+ a = a + 5;
+ b = b + 4;
+ c = c + 3;
+ d = d + 2;
+ e = e + 1;
+ outer--;
+ }
+ return a + b + c + d + e;
}
-word = [0x1001, 0];
-
-var expected = foo(word, 1);
-foo(word, 1);
-%OptimizeFunctionOnNextCall(foo);
-var optimized = foo(word, 1);
-assertEquals(expected, optimized)
+assertEquals(15000015, f(5));
« no previous file with comments | « src/x64/lithium-x64.cc ('k') | test/mjsunit/compiler/osr-nested.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698