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

Unified Diff: src/spaces.h

Issue 21095008: Revert the latest set of platform changes. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/sampler.cc ('k') | src/spaces.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/spaces.h
diff --git a/src/spaces.h b/src/spaces.h
index 165a226219a7fce26f1fd942db55a618b388f19c..b47452e421feeb5c61f8f083d908956eae99a046 100644
--- a/src/spaces.h
+++ b/src/spaces.h
@@ -1444,9 +1444,12 @@ class FreeListCategory {
FreeListCategory() :
top_(NULL),
end_(NULL),
+ mutex_(OS::CreateMutex()),
available_(0) {}
- ~FreeListCategory() {}
+ ~FreeListCategory() {
+ delete mutex_;
+ }
intptr_t Concatenate(FreeListCategory* category);
@@ -1473,7 +1476,7 @@ class FreeListCategory {
int available() const { return available_; }
void set_available(int available) { available_ = available; }
- Mutex* mutex() { return &mutex_; }
+ Mutex* mutex() { return mutex_; }
#ifdef DEBUG
intptr_t SumFreeList();
@@ -1483,7 +1486,7 @@ class FreeListCategory {
private:
FreeListNode* top_;
FreeListNode* end_;
- Mutex mutex_;
+ Mutex* mutex_;
// Total available bytes in all blocks of this free list category.
int available_;
« no previous file with comments | « src/sampler.cc ('k') | src/spaces.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698