| OLD | NEW |
| 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 3023 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3034 ENTER_V8(isolate); | 3034 ENTER_V8(isolate); |
| 3035 i::HandleScope scope(isolate); | 3035 i::HandleScope scope(isolate); |
| 3036 i::Handle<i::JSObject> self = Utils::OpenHandle(this); | 3036 i::Handle<i::JSObject> self = Utils::OpenHandle(this); |
| 3037 i::Handle<i::Object> key_obj = Utils::OpenHandle(*key); | 3037 i::Handle<i::Object> key_obj = Utils::OpenHandle(*key); |
| 3038 | 3038 |
| 3039 // When deleting a property on the global object using ForceDelete | 3039 // When deleting a property on the global object using ForceDelete |
| 3040 // deoptimize all functions as optimized code does not check for the hole | 3040 // deoptimize all functions as optimized code does not check for the hole |
| 3041 // value with DontDelete properties. We have to deoptimize all contexts | 3041 // value with DontDelete properties. We have to deoptimize all contexts |
| 3042 // because of possible cross-context inlined functions. | 3042 // because of possible cross-context inlined functions. |
| 3043 if (self->IsJSGlobalProxy() || self->IsGlobalObject()) { | 3043 if (self->IsJSGlobalProxy() || self->IsGlobalObject()) { |
| 3044 i::Deoptimizer::DeoptimizeAll(); | 3044 i::Deoptimizer::DeoptimizeAll(isolate); |
| 3045 } | 3045 } |
| 3046 | 3046 |
| 3047 EXCEPTION_PREAMBLE(isolate); | 3047 EXCEPTION_PREAMBLE(isolate); |
| 3048 i::Handle<i::Object> obj = i::ForceDeleteProperty(self, key_obj); | 3048 i::Handle<i::Object> obj = i::ForceDeleteProperty(self, key_obj); |
| 3049 has_pending_exception = obj.is_null(); | 3049 has_pending_exception = obj.is_null(); |
| 3050 EXCEPTION_BAILOUT_CHECK(isolate, false); | 3050 EXCEPTION_BAILOUT_CHECK(isolate, false); |
| 3051 return obj->IsTrue(); | 3051 return obj->IsTrue(); |
| 3052 } | 3052 } |
| 3053 | 3053 |
| 3054 | 3054 |
| (...skipping 3864 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6919 SetFlagsFromString(kLazyOptimizations); | 6919 SetFlagsFromString(kLazyOptimizations); |
| 6920 } | 6920 } |
| 6921 #endif | 6921 #endif |
| 6922 } | 6922 } |
| 6923 | 6923 |
| 6924 | 6924 |
| 6925 // TODO(svenpanne) Deprecate this. | 6925 // TODO(svenpanne) Deprecate this. |
| 6926 void Testing::DeoptimizeAll() { | 6926 void Testing::DeoptimizeAll() { |
| 6927 i::Isolate* isolate = i::Isolate::Current(); | 6927 i::Isolate* isolate = i::Isolate::Current(); |
| 6928 i::HandleScope scope(isolate); | 6928 i::HandleScope scope(isolate); |
| 6929 internal::Deoptimizer::DeoptimizeAll(); | 6929 internal::Deoptimizer::DeoptimizeAll(isolate); |
| 6930 } | 6930 } |
| 6931 | 6931 |
| 6932 | 6932 |
| 6933 namespace internal { | 6933 namespace internal { |
| 6934 | 6934 |
| 6935 | 6935 |
| 6936 void HandleScopeImplementer::FreeThreadResources() { | 6936 void HandleScopeImplementer::FreeThreadResources() { |
| 6937 Free(); | 6937 Free(); |
| 6938 } | 6938 } |
| 6939 | 6939 |
| (...skipping 129 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 7069 | 7069 |
| 7070 v->VisitPointers(blocks_.first(), first_block_limit_); | 7070 v->VisitPointers(blocks_.first(), first_block_limit_); |
| 7071 | 7071 |
| 7072 for (int i = 1; i < blocks_.length(); i++) { | 7072 for (int i = 1; i < blocks_.length(); i++) { |
| 7073 v->VisitPointers(blocks_[i], &blocks_[i][kHandleBlockSize]); | 7073 v->VisitPointers(blocks_[i], &blocks_[i][kHandleBlockSize]); |
| 7074 } | 7074 } |
| 7075 } | 7075 } |
| 7076 | 7076 |
| 7077 | 7077 |
| 7078 } } // namespace v8::internal | 7078 } } // namespace v8::internal |
| OLD | NEW |