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_D8_H_ | 5 #ifndef V8_D8_H_ |
6 #define V8_D8_H_ | 6 #define V8_D8_H_ |
7 | 7 |
8 #ifndef V8_SHARED | 8 #ifndef V8_SHARED |
9 #include "src/allocation.h" | 9 #include "src/allocation.h" |
10 #include "src/base/hashmap.h" | 10 #include "src/base/hashmap.h" |
(...skipping 272 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
283 interactive_shell(false), | 283 interactive_shell(false), |
284 test_shell(false), | 284 test_shell(false), |
285 dump_heap_constants(false), | 285 dump_heap_constants(false), |
286 expected_to_throw(false), | 286 expected_to_throw(false), |
287 mock_arraybuffer_allocator(false), | 287 mock_arraybuffer_allocator(false), |
288 num_isolates(1), | 288 num_isolates(1), |
289 compile_options(v8::ScriptCompiler::kNoCompileOptions), | 289 compile_options(v8::ScriptCompiler::kNoCompileOptions), |
290 isolate_sources(NULL), | 290 isolate_sources(NULL), |
291 icu_data_file(NULL), | 291 icu_data_file(NULL), |
292 natives_blob(NULL), | 292 natives_blob(NULL), |
293 snapshot_blob(NULL) {} | 293 snapshot_blob(NULL), |
| 294 trace_enabled(false), |
| 295 trace_config(NULL) {} |
294 | 296 |
295 ~ShellOptions() { | 297 ~ShellOptions() { |
296 delete[] isolate_sources; | 298 delete[] isolate_sources; |
297 } | 299 } |
298 | 300 |
299 bool use_interactive_shell() { | 301 bool use_interactive_shell() { |
300 return (interactive_shell || !script_executed) && !test_shell; | 302 return (interactive_shell || !script_executed) && !test_shell; |
301 } | 303 } |
302 | 304 |
303 bool script_executed; | 305 bool script_executed; |
304 bool send_idle_notification; | 306 bool send_idle_notification; |
305 bool invoke_weak_callbacks; | 307 bool invoke_weak_callbacks; |
306 bool omit_quit; | 308 bool omit_quit; |
307 bool stress_opt; | 309 bool stress_opt; |
308 bool stress_deopt; | 310 bool stress_deopt; |
309 int stress_runs; | 311 int stress_runs; |
310 bool interactive_shell; | 312 bool interactive_shell; |
311 bool test_shell; | 313 bool test_shell; |
312 bool dump_heap_constants; | 314 bool dump_heap_constants; |
313 bool expected_to_throw; | 315 bool expected_to_throw; |
314 bool mock_arraybuffer_allocator; | 316 bool mock_arraybuffer_allocator; |
315 int num_isolates; | 317 int num_isolates; |
316 v8::ScriptCompiler::CompileOptions compile_options; | 318 v8::ScriptCompiler::CompileOptions compile_options; |
317 SourceGroup* isolate_sources; | 319 SourceGroup* isolate_sources; |
318 const char* icu_data_file; | 320 const char* icu_data_file; |
319 const char* natives_blob; | 321 const char* natives_blob; |
320 const char* snapshot_blob; | 322 const char* snapshot_blob; |
| 323 bool trace_enabled; |
| 324 const char* trace_config; |
321 }; | 325 }; |
322 | 326 |
323 #ifdef V8_SHARED | 327 #ifdef V8_SHARED |
324 class Shell { | 328 class Shell { |
325 #else | 329 #else |
326 class Shell : public i::AllStatic { | 330 class Shell : public i::AllStatic { |
327 #endif // V8_SHARED | 331 #endif // V8_SHARED |
328 | 332 |
329 public: | 333 public: |
330 enum SourceType { SCRIPT, MODULE }; | 334 enum SourceType { SCRIPT, MODULE }; |
(...skipping 142 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
473 static Local<ObjectTemplate> CreateGlobalTemplate(Isolate* isolate); | 477 static Local<ObjectTemplate> CreateGlobalTemplate(Isolate* isolate); |
474 static MaybeLocal<Context> CreateRealm( | 478 static MaybeLocal<Context> CreateRealm( |
475 const v8::FunctionCallbackInfo<v8::Value>& args); | 479 const v8::FunctionCallbackInfo<v8::Value>& args); |
476 }; | 480 }; |
477 | 481 |
478 | 482 |
479 } // namespace v8 | 483 } // namespace v8 |
480 | 484 |
481 | 485 |
482 #endif // V8_D8_H_ | 486 #endif // V8_D8_H_ |
OLD | NEW |