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

Side by Side Diff: src/runtime.cc

Issue 12317141: Added Isolate parameter to CodeStub::GetCode(). (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Fixed whitespace. Rebased. Created 7 years, 9 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
« no previous file with comments | « src/mips/stub-cache-mips.cc ('k') | src/stub-cache.cc » ('j') | 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 // 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 8033 matching lines...) Expand 10 before | Expand all | Expand 10 after
8044 } 8044 }
8045 } 8045 }
8046 8046
8047 // Revert to the original stack checks in the original unoptimized code. 8047 // Revert to the original stack checks in the original unoptimized code.
8048 if (FLAG_trace_osr) { 8048 if (FLAG_trace_osr) {
8049 PrintF("[restoring original stack checks in "); 8049 PrintF("[restoring original stack checks in ");
8050 function->PrintName(); 8050 function->PrintName();
8051 PrintF("]\n"); 8051 PrintF("]\n");
8052 } 8052 }
8053 InterruptStub interrupt_stub; 8053 InterruptStub interrupt_stub;
8054 Handle<Code> check_code = interrupt_stub.GetCode(); 8054 Handle<Code> check_code = interrupt_stub.GetCode(isolate);
8055 Handle<Code> replacement_code = isolate->builtins()->OnStackReplacement(); 8055 Handle<Code> replacement_code = isolate->builtins()->OnStackReplacement();
8056 Deoptimizer::RevertStackCheckCode(*unoptimized, 8056 Deoptimizer::RevertStackCheckCode(*unoptimized,
8057 *check_code, 8057 *check_code,
8058 *replacement_code); 8058 *replacement_code);
8059 8059
8060 // Allow OSR only at nesting level zero again. 8060 // Allow OSR only at nesting level zero again.
8061 unoptimized->set_allow_osr_at_loop_nesting_level(0); 8061 unoptimized->set_allow_osr_at_loop_nesting_level(0);
8062 8062
8063 // If the optimization attempt succeeded, return the AST id tagged as a 8063 // If the optimization attempt succeeded, return the AST id tagged as a
8064 // smi. This tells the builtin that we need to translate the unoptimized 8064 // smi. This tells the builtin that we need to translate the unoptimized
(...skipping 5270 matching lines...) Expand 10 before | Expand all | Expand 10 after
13335 // Handle last resort GC and make sure to allow future allocations 13335 // Handle last resort GC and make sure to allow future allocations
13336 // to grow the heap without causing GCs (if possible). 13336 // to grow the heap without causing GCs (if possible).
13337 isolate->counters()->gc_last_resort_from_js()->Increment(); 13337 isolate->counters()->gc_last_resort_from_js()->Increment();
13338 isolate->heap()->CollectAllGarbage(Heap::kNoGCFlags, 13338 isolate->heap()->CollectAllGarbage(Heap::kNoGCFlags,
13339 "Runtime::PerformGC"); 13339 "Runtime::PerformGC");
13340 } 13340 }
13341 } 13341 }
13342 13342
13343 13343
13344 } } // namespace v8::internal 13344 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/mips/stub-cache-mips.cc ('k') | src/stub-cache.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698