| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "src/isolate.h" | 5 #include "src/isolate.h" |
| 6 | 6 |
| 7 #include <stdlib.h> | 7 #include <stdlib.h> |
| 8 | 8 |
| 9 #include <fstream> // NOLINT(readability/streams) | 9 #include <fstream> // NOLINT(readability/streams) |
| 10 #include <sstream> | 10 #include <sstream> |
| (...skipping 2935 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2946 | 2946 |
| 2947 void Isolate::InvalidateStringLengthOverflowProtector() { | 2947 void Isolate::InvalidateStringLengthOverflowProtector() { |
| 2948 DCHECK(factory()->string_length_protector()->value()->IsSmi()); | 2948 DCHECK(factory()->string_length_protector()->value()->IsSmi()); |
| 2949 DCHECK(IsStringLengthOverflowIntact()); | 2949 DCHECK(IsStringLengthOverflowIntact()); |
| 2950 PropertyCell::SetValueWithInvalidation( | 2950 PropertyCell::SetValueWithInvalidation( |
| 2951 factory()->string_length_protector(), | 2951 factory()->string_length_protector(), |
| 2952 handle(Smi::FromInt(kArrayProtectorInvalid), this)); | 2952 handle(Smi::FromInt(kArrayProtectorInvalid), this)); |
| 2953 DCHECK(!IsStringLengthOverflowIntact()); | 2953 DCHECK(!IsStringLengthOverflowIntact()); |
| 2954 } | 2954 } |
| 2955 | 2955 |
| 2956 void Isolate::InvalidateArrayIteratorProtector() { |
| 2957 DCHECK(factory()->array_iterator_protector()->value()->IsSmi()); |
| 2958 DCHECK(IsArrayIteratorLookupChainIntact()); |
| 2959 factory()->array_iterator_protector()->set_value( |
| 2960 Smi::FromInt(kArrayProtectorInvalid)); |
| 2961 DCHECK(!IsArrayIteratorLookupChainIntact()); |
| 2962 } |
| 2963 |
| 2956 bool Isolate::IsAnyInitialArrayPrototype(Handle<JSArray> array) { | 2964 bool Isolate::IsAnyInitialArrayPrototype(Handle<JSArray> array) { |
| 2957 DisallowHeapAllocation no_gc; | 2965 DisallowHeapAllocation no_gc; |
| 2958 return IsInAnyContext(*array, Context::INITIAL_ARRAY_PROTOTYPE_INDEX); | 2966 return IsInAnyContext(*array, Context::INITIAL_ARRAY_PROTOTYPE_INDEX); |
| 2959 } | 2967 } |
| 2960 | 2968 |
| 2961 | 2969 |
| 2962 CallInterfaceDescriptorData* Isolate::call_descriptor_data(int index) { | 2970 CallInterfaceDescriptorData* Isolate::call_descriptor_data(int index) { |
| 2963 DCHECK(0 <= index && index < CallDescriptors::NUMBER_OF_DESCRIPTORS); | 2971 DCHECK(0 <= index && index < CallDescriptors::NUMBER_OF_DESCRIPTORS); |
| 2964 return &call_descriptor_data_[index]; | 2972 return &call_descriptor_data_[index]; |
| 2965 } | 2973 } |
| (...skipping 523 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3489 // Then check whether this scope intercepts. | 3497 // Then check whether this scope intercepts. |
| 3490 if ((flag & intercept_mask_)) { | 3498 if ((flag & intercept_mask_)) { |
| 3491 intercepted_flags_ |= flag; | 3499 intercepted_flags_ |= flag; |
| 3492 return true; | 3500 return true; |
| 3493 } | 3501 } |
| 3494 return false; | 3502 return false; |
| 3495 } | 3503 } |
| 3496 | 3504 |
| 3497 } // namespace internal | 3505 } // namespace internal |
| 3498 } // namespace v8 | 3506 } // namespace v8 |
| OLD | NEW |