Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1)

Side by Side Diff: src/isolate.cc

Issue 196983011: Clean up some isolate macros. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/isolate.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 1532 matching lines...) Expand 10 before | Expand all | Expand 10 after
1543 context_slot_cache_(NULL), 1543 context_slot_cache_(NULL),
1544 descriptor_lookup_cache_(NULL), 1544 descriptor_lookup_cache_(NULL),
1545 handle_scope_implementer_(NULL), 1545 handle_scope_implementer_(NULL),
1546 unicode_cache_(NULL), 1546 unicode_cache_(NULL),
1547 runtime_zone_(this), 1547 runtime_zone_(this),
1548 inner_pointer_to_code_cache_(NULL), 1548 inner_pointer_to_code_cache_(NULL),
1549 write_iterator_(NULL), 1549 write_iterator_(NULL),
1550 global_handles_(NULL), 1550 global_handles_(NULL),
1551 eternal_handles_(NULL), 1551 eternal_handles_(NULL),
1552 thread_manager_(NULL), 1552 thread_manager_(NULL),
1553 fp_stubs_generated_(false),
1554 has_installed_extensions_(false), 1553 has_installed_extensions_(false),
1555 string_tracker_(NULL), 1554 string_tracker_(NULL),
1556 regexp_stack_(NULL), 1555 regexp_stack_(NULL),
1557 date_cache_(NULL), 1556 date_cache_(NULL),
1558 code_stub_interface_descriptors_(NULL), 1557 code_stub_interface_descriptors_(NULL),
1559 call_descriptors_(NULL), 1558 call_descriptors_(NULL),
1560 // TODO(bmeurer) Initialized lazily because it depends on flags; can 1559 // TODO(bmeurer) Initialized lazily because it depends on flags; can
1561 // be fixed once the default isolate cleanup is done. 1560 // be fixed once the default isolate cleanup is done.
1562 random_number_generator_(NULL), 1561 random_number_generator_(NULL),
1563 has_fatal_error_(false), 1562 has_fatal_error_(false),
1564 use_crankshaft_(true), 1563 use_crankshaft_(true),
1565 initialized_from_snapshot_(false), 1564 initialized_from_snapshot_(false),
1566 cpu_profiler_(NULL), 1565 cpu_profiler_(NULL),
1567 heap_profiler_(NULL), 1566 heap_profiler_(NULL),
1568 function_entry_hook_(NULL), 1567 function_entry_hook_(NULL),
1569 deferred_handles_head_(NULL), 1568 deferred_handles_head_(NULL),
1570 optimizing_compiler_thread_(NULL), 1569 optimizing_compiler_thread_(NULL),
1571 sweeper_thread_(NULL), 1570 sweeper_thread_(NULL),
1572 num_sweeper_threads_(0), 1571 num_sweeper_threads_(0),
1573 max_available_threads_(0),
1574 stress_deopt_count_(0), 1572 stress_deopt_count_(0),
1575 next_optimization_id_(0) { 1573 next_optimization_id_(0) {
1576 id_ = NoBarrier_AtomicIncrement(&isolate_counter_, 1); 1574 id_ = NoBarrier_AtomicIncrement(&isolate_counter_, 1);
1577 TRACE_ISOLATE(constructor); 1575 TRACE_ISOLATE(constructor);
1578 1576
1579 memset(isolate_addresses_, 0, 1577 memset(isolate_addresses_, 0,
1580 sizeof(isolate_addresses_[0]) * (kIsolateAddressCount + 1)); 1578 sizeof(isolate_addresses_[0]) * (kIsolateAddressCount + 1));
1581 1579
1582 heap_.isolate_ = this; 1580 heap_.isolate_ = this;
1583 stack_guard_.isolate_ = this; 1581 stack_guard_.isolate_ = this;
1584 1582
1585 // ThreadManager is initialized early to support locking an isolate 1583 // ThreadManager is initialized early to support locking an isolate
1586 // before it is entered. 1584 // before it is entered.
1587 thread_manager_ = new ThreadManager(); 1585 thread_manager_ = new ThreadManager();
1588 thread_manager_->isolate_ = this; 1586 thread_manager_->isolate_ = this;
1589 1587
1590 #if V8_TARGET_ARCH_ARM && !defined(__arm__) || \
1591 V8_TARGET_ARCH_A64 && !defined(__aarch64__) || \
1592 V8_TARGET_ARCH_MIPS && !defined(__mips__)
1593 simulator_initialized_ = false;
1594 simulator_i_cache_ = NULL;
1595 simulator_redirection_ = NULL;
1596 #endif
1597
1598 #ifdef DEBUG 1588 #ifdef DEBUG
1599 // heap_histograms_ initializes itself. 1589 // heap_histograms_ initializes itself.
1600 memset(&js_spill_information_, 0, sizeof(js_spill_information_)); 1590 memset(&js_spill_information_, 0, sizeof(js_spill_information_));
1601 memset(code_kind_statistics_, 0,
1602 sizeof(code_kind_statistics_[0]) * Code::NUMBER_OF_KINDS);
1603 #endif 1591 #endif
1604 1592
1605 #ifdef ENABLE_DEBUGGER_SUPPORT 1593 #ifdef ENABLE_DEBUGGER_SUPPORT
1606 debug_ = NULL; 1594 debug_ = NULL;
1607 debugger_ = NULL; 1595 debugger_ = NULL;
1608 #endif 1596 #endif
1609 1597
1610 handle_scope_data_.Initialize(); 1598 handle_scope_data_.Initialize();
1611 1599
1612 #define ISOLATE_INIT_EXECUTE(type, name, initial_value) \ 1600 #define ISOLATE_INIT_EXECUTE(type, name, initial_value) \
(...skipping 716 matching lines...) Expand 10 before | Expand all | Expand 10 after
2329 2317
2330 #ifdef DEBUG 2318 #ifdef DEBUG
2331 #define ISOLATE_FIELD_OFFSET(type, name, ignored) \ 2319 #define ISOLATE_FIELD_OFFSET(type, name, ignored) \
2332 const intptr_t Isolate::name##_debug_offset_ = OFFSET_OF(Isolate, name##_); 2320 const intptr_t Isolate::name##_debug_offset_ = OFFSET_OF(Isolate, name##_);
2333 ISOLATE_INIT_LIST(ISOLATE_FIELD_OFFSET) 2321 ISOLATE_INIT_LIST(ISOLATE_FIELD_OFFSET)
2334 ISOLATE_INIT_ARRAY_LIST(ISOLATE_FIELD_OFFSET) 2322 ISOLATE_INIT_ARRAY_LIST(ISOLATE_FIELD_OFFSET)
2335 #undef ISOLATE_FIELD_OFFSET 2323 #undef ISOLATE_FIELD_OFFSET
2336 #endif 2324 #endif
2337 2325
2338 } } // namespace v8::internal 2326 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/isolate.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698