| Index: src/isolate.cc
|
| diff --git a/src/isolate.cc b/src/isolate.cc
|
| index 7a3570f6a0d0828d20660c2a3ec149372d4a2250..92ec2b3b548150c137b64822f5cba21878b5be09 100644
|
| --- a/src/isolate.cc
|
| +++ b/src/isolate.cc
|
| @@ -2822,6 +2822,26 @@ bool Isolate::IsArrayOrObjectPrototype(Object* object) {
|
| return false;
|
| }
|
|
|
| +void Isolate::ClearOSROptimizedCode() {
|
| + DisallowHeapAllocation no_gc;
|
| + Object* context = heap()->native_contexts_list();
|
| + while (!context->IsUndefined(this)) {
|
| + Context* current_context = Context::cast(context);
|
| + current_context->ClearOptimizedCodeMap();
|
| + context = current_context->next_context_link();
|
| + }
|
| +}
|
| +
|
| +void Isolate::EvictOSROptimizedCode(Code* code, const char* reason) {
|
| + DisallowHeapAllocation no_gc;
|
| + Object* context = heap()->native_contexts_list();
|
| + while (!context->IsUndefined(this)) {
|
| + Context* current_context = Context::cast(context);
|
| + current_context->EvictFromOptimizedCodeMap(code, reason);
|
| + context = current_context->next_context_link();
|
| + }
|
| +}
|
| +
|
| bool Isolate::IsInAnyContext(Object* object, uint32_t index) {
|
| DisallowHeapAllocation no_gc;
|
| Object* context = heap()->native_contexts_list();
|
|
|