| 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 #ifndef V8_API_H_ | 5 #ifndef V8_API_H_ |
| 6 #define V8_API_H_ | 6 #define V8_API_H_ |
| 7 | 7 |
| 8 #include "include/v8-testing.h" | 8 #include "include/v8-testing.h" |
| 9 #include "src/contexts.h" | 9 #include "src/contexts.h" |
| 10 #include "src/debug/debug-interface.h" | 10 #include "src/debug/debug-interface.h" |
| (...skipping 329 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 340 (*reinterpret_cast<v8::internal::Object* const*>(that))->Is##To()); \ | 340 (*reinterpret_cast<v8::internal::Object* const*>(that))->Is##To()); \ |
| 341 return v8::internal::Handle<v8::internal::To>( \ | 341 return v8::internal::Handle<v8::internal::To>( \ |
| 342 reinterpret_cast<v8::internal::To**>(const_cast<v8::From*>(that))); \ | 342 reinterpret_cast<v8::internal::To**>(const_cast<v8::From*>(that))); \ |
| 343 } | 343 } |
| 344 | 344 |
| 345 OPEN_HANDLE_LIST(MAKE_OPEN_HANDLE) | 345 OPEN_HANDLE_LIST(MAKE_OPEN_HANDLE) |
| 346 | 346 |
| 347 #undef MAKE_OPEN_HANDLE | 347 #undef MAKE_OPEN_HANDLE |
| 348 #undef OPEN_HANDLE_LIST | 348 #undef OPEN_HANDLE_LIST |
| 349 | 349 |
| 350 extern Isolate* IsolateNewImpl(internal::Isolate* isolate, |
| 351 const Isolate::CreateParams& params); |
| 350 | 352 |
| 351 namespace internal { | 353 namespace internal { |
| 352 | 354 |
| 353 class V8_EXPORT_PRIVATE DeferredHandles { | 355 class V8_EXPORT_PRIVATE DeferredHandles { |
| 354 public: | 356 public: |
| 355 ~DeferredHandles(); | 357 ~DeferredHandles(); |
| 356 | 358 |
| 357 private: | 359 private: |
| 358 DeferredHandles(Object** first_block_limit, Isolate* isolate) | 360 DeferredHandles(Object** first_block_limit, Isolate* isolate) |
| 359 : next_(NULL), | 361 : next_(NULL), |
| (...skipping 278 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 638 #endif | 640 #endif |
| 639 if (spare_ != NULL) { | 641 if (spare_ != NULL) { |
| 640 DeleteArray(spare_); | 642 DeleteArray(spare_); |
| 641 } | 643 } |
| 642 spare_ = block_start; | 644 spare_ = block_start; |
| 643 } | 645 } |
| 644 DCHECK((blocks_.is_empty() && prev_limit == NULL) || | 646 DCHECK((blocks_.is_empty() && prev_limit == NULL) || |
| 645 (!blocks_.is_empty() && prev_limit != NULL)); | 647 (!blocks_.is_empty() && prev_limit != NULL)); |
| 646 } | 648 } |
| 647 | 649 |
| 648 | |
| 649 // Interceptor functions called from generated inline caches to notify | 650 // Interceptor functions called from generated inline caches to notify |
| 650 // CPU profiler that external callbacks are invoked. | 651 // CPU profiler that external callbacks are invoked. |
| 651 void InvokeAccessorGetterCallback( | 652 void InvokeAccessorGetterCallback( |
| 652 v8::Local<v8::Name> property, | 653 v8::Local<v8::Name> property, |
| 653 const v8::PropertyCallbackInfo<v8::Value>& info, | 654 const v8::PropertyCallbackInfo<v8::Value>& info, |
| 654 v8::AccessorNameGetterCallback getter); | 655 v8::AccessorNameGetterCallback getter); |
| 655 | 656 |
| 656 void InvokeFunctionCallback(const v8::FunctionCallbackInfo<v8::Value>& info, | 657 void InvokeFunctionCallback(const v8::FunctionCallbackInfo<v8::Value>& info, |
| 657 v8::FunctionCallback callback); | 658 v8::FunctionCallback callback); |
| 658 | 659 |
| 659 class Testing { | 660 class Testing { |
| 660 public: | 661 public: |
| 661 static v8::Testing::StressType stress_type() { return stress_type_; } | 662 static v8::Testing::StressType stress_type() { return stress_type_; } |
| 662 static void set_stress_type(v8::Testing::StressType stress_type) { | 663 static void set_stress_type(v8::Testing::StressType stress_type) { |
| 663 stress_type_ = stress_type; | 664 stress_type_ = stress_type; |
| 664 } | 665 } |
| 665 | 666 |
| 666 private: | 667 private: |
| 667 static v8::Testing::StressType stress_type_; | 668 static v8::Testing::StressType stress_type_; |
| 668 }; | 669 }; |
| 669 | 670 |
| 670 } // namespace internal | 671 } // namespace internal |
| 671 } // namespace v8 | 672 } // namespace v8 |
| 672 | 673 |
| 673 #endif // V8_API_H_ | 674 #endif // V8_API_H_ |
| OLD | NEW |