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

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

Issue 11417026: Disable InstanceOfStubWriteBarrier in some cases. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 8 years, 1 month 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 2
3 #include <stdlib.h> 3 #include <stdlib.h>
4 4
5 #include "v8.h" 5 #include "v8.h"
6 6
7 #include "compilation-cache.h" 7 #include "compilation-cache.h"
8 #include "execution.h" 8 #include "execution.h"
9 #include "factory.h" 9 #include "factory.h"
10 #include "macro-assembler.h" 10 #include "macro-assembler.h"
(...skipping 1715 matching lines...) Expand 10 before | Expand all | Expand 10 after
1726 1726
1727 1727
1728 TEST(InstanceOfStubWriteBarrier) { 1728 TEST(InstanceOfStubWriteBarrier) {
1729 i::FLAG_allow_natives_syntax = true; 1729 i::FLAG_allow_natives_syntax = true;
1730 #ifdef VERIFY_HEAP 1730 #ifdef VERIFY_HEAP
1731 i::FLAG_verify_heap = true; 1731 i::FLAG_verify_heap = true;
1732 #endif 1732 #endif
1733 1733
1734 InitializeVM(); 1734 InitializeVM();
1735 if (!i::V8::UseCrankshaft()) return; 1735 if (!i::V8::UseCrankshaft()) return;
1736 if (i::FLAG_force_marking_deque_overflows) return;
1736 v8::HandleScope outer_scope; 1737 v8::HandleScope outer_scope;
1737 1738
1738 { 1739 {
1739 v8::HandleScope scope; 1740 v8::HandleScope scope;
1740 CompileRun( 1741 CompileRun(
1741 "function foo () { }" 1742 "function foo () { }"
1742 "function mkbar () { return new (new Function(\"\")) (); }" 1743 "function mkbar () { return new (new Function(\"\")) (); }"
1743 "function f (x) { return (x instanceof foo); }" 1744 "function f (x) { return (x instanceof foo); }"
1744 "function g () { f(mkbar()); }" 1745 "function g () { f(mkbar()); }"
1745 "f(new foo()); f(new foo());" 1746 "f(new foo()); f(new foo());"
(...skipping 758 matching lines...) Expand 10 before | Expand all | Expand 10 after
2504 Handle<Object> call_function(call); 2505 Handle<Object> call_function(call);
2505 2506
2506 // Now we are ready to mess up the heap. 2507 // Now we are ready to mess up the heap.
2507 HEAP->CollectAllGarbage(Heap::kReduceMemoryFootprintMask); 2508 HEAP->CollectAllGarbage(Heap::kReduceMemoryFootprintMask);
2508 2509
2509 // Either heap verification caught the problem already or we go kaboom once 2510 // Either heap verification caught the problem already or we go kaboom once
2510 // the CallIC is executed the next time. 2511 // the CallIC is executed the next time.
2511 USE(global->SetProperty(*name, *call_function, NONE, kNonStrictMode)); 2512 USE(global->SetProperty(*name, *call_function, NONE, kNonStrictMode));
2512 CompileRun("call();"); 2513 CompileRun("call();");
2513 } 2514 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698