thread_local_.step_into_fp_ = 0;
thread_local_.step_out_fp_ = 0;
// TODO(isolates): frames_are_dropped_?
- thread_local_.current_debug_scope_ = NULL;
+ base::NoBarrier_Store(&thread_local_.current_debug_scope_,
+ static_cast<base::AtomicWord>(NULL));
thread_local_.restarter_frame_function_pointer_ = NULL;
}
no_termination_exceptons_(debug_->isolate_,
StackGuard::TERMINATE_EXECUTION) {
// Link recursive debugger entry.
- debug_->thread_local_.current_debug_scope_ = this;
+ base::NoBarrier_Store(&debug_->thread_local_.current_debug_scope_,
+ reinterpret_cast<base::AtomicWord>(this));
// Store the previous break id and frame id.
break_id_ = debug_->break_id();
}
// Leaving this debugger entry.
- debug_->thread_local_.current_debug_scope_ = prev_;
+ base::NoBarrier_Store(&debug_->thread_local_.current_debug_scope_,
+ reinterpret_cast<base::AtomicWord>(prev_));
// Restore to the previous break state.
debug_->thread_local_.break_frame_id_ = break_frame_id_;
#include "src/allocation.h"
#include "src/arguments.h"
#include "src/assembler.h"
+#include "src/base/atomicops.h"
#include "src/base/platform/platform.h"
#include "src/execution.h"
#include "src/factory.h"
}
// Flags and states.
- DebugScope* debugger_entry() { return thread_local_.current_debug_scope_; }
+ DebugScope* debugger_entry() {
+ return reinterpret_cast<DebugScope*>(
+ base::NoBarrier_Load(&thread_local_.current_debug_scope_));
+ }
inline Handle<Context> debug_context() { return debug_context_; }
void set_live_edit_enabled(bool v) { live_edit_enabled_ = v; }
bool live_edit_enabled() const {
inline bool is_loaded() const { return !debug_context_.is_null(); }
inline bool has_break_points() const { return has_break_points_; }
inline bool in_debug_scope() const {
- return thread_local_.current_debug_scope_ != NULL;
+ return !!base::NoBarrier_Load(&thread_local_.current_debug_scope_);
}
void set_disable_break(bool v) { break_disabled_ = v; }
class ThreadLocal {
public:
// Top debugger entry.
- DebugScope* current_debug_scope_;
+ base::AtomicWord current_debug_scope_;
// Counter for generating next break id.
int break_count_;