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

Unified Diff: src/store-buffer.cc

Issue 23641009: Refactor and cleanup VirtualMemory. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Addressed nits. Created 7 years, 3 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/spaces-inl.h ('k') | src/v8globals.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/store-buffer.cc
diff --git a/src/store-buffer.cc b/src/store-buffer.cc
index 22a546742c85f376839ef68528728cd69bb3cc53..7a0dc88a81d5b695e6ba87dc2eeabbbd8c55e0b0 100644
--- a/src/store-buffer.cc
+++ b/src/store-buffer.cc
@@ -72,7 +72,8 @@ void StoreBuffer::SetUp() {
// Don't know the alignment requirements of the OS, but it is certainly not
// less than 0xfff.
ASSERT((reinterpret_cast<uintptr_t>(old_start_) & 0xfff) == 0);
- int initial_length = static_cast<int>(OS::CommitPageSize() / kPointerSize);
+ int initial_length =
+ static_cast<int>(VirtualMemory::GetPageSize() / kPointerSize);
ASSERT(initial_length > 0);
ASSERT(initial_length <= kOldStoreBufferLength);
old_limit_ = old_start_ + initial_length;
@@ -81,7 +82,7 @@ void StoreBuffer::SetUp() {
CHECK(old_virtual_memory_->Commit(
reinterpret_cast<void*>(old_start_),
(old_limit_ - old_start_) * kPointerSize,
- false));
+ VirtualMemory::NOT_EXECUTABLE));
ASSERT(reinterpret_cast<Address>(start_) >= virtual_memory_->address());
ASSERT(reinterpret_cast<Address>(limit_) >= virtual_memory_->address());
@@ -97,7 +98,7 @@ void StoreBuffer::SetUp() {
CHECK(virtual_memory_->Commit(reinterpret_cast<Address>(start_),
kStoreBufferSize,
- false)); // Not executable.
+ VirtualMemory::NOT_EXECUTABLE));
heap_->public_set_store_buffer_top(start_);
hash_set_1_ = new uintptr_t[kHashSetLength];
@@ -154,7 +155,7 @@ void StoreBuffer::EnsureSpace(intptr_t space_needed) {
size_t grow = old_limit_ - old_start_; // Double size.
CHECK(old_virtual_memory_->Commit(reinterpret_cast<void*>(old_limit_),
grow * kPointerSize,
- false));
+ VirtualMemory::NOT_EXECUTABLE));
old_limit_ += grow;
}
« no previous file with comments | « src/spaces-inl.h ('k') | src/v8globals.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698