Fix concurrent access to VMState::current_state_.
authormikhail.naganov@gmail.com <mikhail.naganov@gmail.com@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Thu, 8 Jul 2010 08:00:38 +0000 (08:00 +0000)
committermikhail.naganov@gmail.com <mikhail.naganov@gmail.com@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Thu, 8 Jul 2010 08:00:38 +0000 (08:00 +0000)
commit03b566be92c303d7200722f8bb9d72417bce0f8e
treef3909acfdbfc3e1bde7b4649dc1aaf11cac74aa8
parent149dea4ab04e00c529fbb4b3988329e607684cd0
Fix concurrent access to VMState::current_state_.

The main fix is for current_state() and external_callback() accessors.
I also applied memory access ordering on current_state_ modification,
mainly to reflect the fact that it is being shared among VM and profiler
sampler threads.

BUG=361

Review URL: http://codereview.chromium.org/2852047

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@5035 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
src/vm-state-inl.h
src/vm-state.cc
src/vm-state.h