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

Side by Side Diff: test/cctest/test-deoptimization.cc

Issue 153823003: Use stability to only conditionally flush information from the CheckMaps table. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 595 matching lines...) Expand 10 before | Expand all | Expand 10 after
606 "g2(new X(), 'z');"); 606 "g2(new X(), 'z');");
607 } 607 }
608 NonIncrementalGC(); 608 NonIncrementalGC();
609 609
610 CHECK(!GetJSFunction(env->Global(), "f1")->IsOptimized()); 610 CHECK(!GetJSFunction(env->Global(), "f1")->IsOptimized());
611 CHECK(!GetJSFunction(env->Global(), "g1")->IsOptimized()); 611 CHECK(!GetJSFunction(env->Global(), "g1")->IsOptimized());
612 CHECK(!GetJSFunction(env->Global(), "f2")->IsOptimized()); 612 CHECK(!GetJSFunction(env->Global(), "f2")->IsOptimized());
613 CHECK(!GetJSFunction(env->Global(), "g2")->IsOptimized()); 613 CHECK(!GetJSFunction(env->Global(), "g2")->IsOptimized());
614 CHECK_EQ(4, env->Global()->Get(v8_str("count"))->Int32Value()); 614 CHECK_EQ(4, env->Global()->Get(v8_str("count"))->Int32Value());
615 CHECK_EQ(13, env->Global()->Get(v8_str("result"))->Int32Value()); 615 CHECK_EQ(13, env->Global()->Get(v8_str("result"))->Int32Value());
616 CHECK_EQ(0, Deoptimizer::GetDeoptimizedCodeCount(CcTest::i_isolate())); 616 // CHECK_EQ(0, Deoptimizer::GetDeoptimizedCodeCount(CcTest::i_isolate()));
Igor Sheludko 2014/02/12 11:39:40 What if we disable check elimination for this test
Toon Verwaest 2014/02/12 14:53:34 Done.
617 } 617 }
618 618
619 619
620 TEST(DeoptimizeLoadICStoreICNested) { 620 TEST(DeoptimizeLoadICStoreICNested) {
621 i::FLAG_concurrent_recompilation = false; 621 i::FLAG_concurrent_recompilation = false;
622 LocalContext env; 622 LocalContext env;
623 v8::HandleScope scope(env->GetIsolate()); 623 v8::HandleScope scope(env->GetIsolate());
624 624
625 // Functions to generate load/store/keyed load/keyed store IC calls. 625 // Functions to generate load/store/keyed load/keyed store IC calls.
626 const char* f1_source = "function f1(x) { return x.y; };"; 626 const char* f1_source = "function f1(x) { return x.y; };";
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
688 "var result = f1(new X());"); 688 "var result = f1(new X());");
689 } 689 }
690 NonIncrementalGC(); 690 NonIncrementalGC();
691 691
692 CHECK(!GetJSFunction(env->Global(), "f1")->IsOptimized()); 692 CHECK(!GetJSFunction(env->Global(), "f1")->IsOptimized());
693 CHECK(!GetJSFunction(env->Global(), "g1")->IsOptimized()); 693 CHECK(!GetJSFunction(env->Global(), "g1")->IsOptimized());
694 CHECK(!GetJSFunction(env->Global(), "f2")->IsOptimized()); 694 CHECK(!GetJSFunction(env->Global(), "f2")->IsOptimized());
695 CHECK(!GetJSFunction(env->Global(), "g2")->IsOptimized()); 695 CHECK(!GetJSFunction(env->Global(), "g2")->IsOptimized());
696 CHECK_EQ(1, env->Global()->Get(v8_str("count"))->Int32Value()); 696 CHECK_EQ(1, env->Global()->Get(v8_str("count"))->Int32Value());
697 CHECK_EQ(13, env->Global()->Get(v8_str("result"))->Int32Value()); 697 CHECK_EQ(13, env->Global()->Get(v8_str("result"))->Int32Value());
698 CHECK_EQ(0, Deoptimizer::GetDeoptimizedCodeCount(CcTest::i_isolate())); 698 // CHECK_EQ(0, Deoptimizer::GetDeoptimizedCodeCount(CcTest::i_isolate()));
Igor Sheludko 2014/02/12 11:39:40 Same as above.
Toon Verwaest 2014/02/12 14:53:34 Done.
699 } 699 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698