diff options
author | Ryan <ry@tinyclouds.org> | 2009-06-08 18:34:06 +0200 |
---|---|---|
committer | Ryan <ry@tinyclouds.org> | 2009-06-08 18:34:06 +0200 |
commit | 696f02455792b368249bf9b013dde637b5ec31fd (patch) | |
tree | 95b2dbd6c2537df9df52f6627aac36fcf05f6a7a /deps/v8/src/spaces-inl.h | |
parent | f6a7fe26574defaa807a13248102ebe0f23270af (diff) | |
download | node-new-696f02455792b368249bf9b013dde637b5ec31fd.tar.gz |
Upgrade to v8 1.2.7
Diffstat (limited to 'deps/v8/src/spaces-inl.h')
-rw-r--r-- | deps/v8/src/spaces-inl.h | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/deps/v8/src/spaces-inl.h b/deps/v8/src/spaces-inl.h index 3973658472..2f01164f89 100644 --- a/deps/v8/src/spaces-inl.h +++ b/deps/v8/src/spaces-inl.h @@ -31,7 +31,8 @@ #include "memory.h" #include "spaces.h" -namespace v8 { namespace internal { +namespace v8 { +namespace internal { // ----------------------------------------------------------------------------- @@ -92,8 +93,10 @@ Address Page::AllocationTop() { void Page::ClearRSet() { +#ifndef V8_HOST_ARCH_64_BIT // This method can be called in all rset states. memset(RSetStart(), 0, kRSetEndOffset - kRSetStartOffset); +#endif } @@ -157,9 +160,14 @@ void Page::UnsetRSet(Address address, int offset) { bool Page::IsRSetSet(Address address, int offset) { +#ifdef V8_HOST_ARCH_64_BIT + // TODO(X64): Reenable when RSet works. + return true; +#else // V8_HOST_ARCH_64_BIT uint32_t bitmask = 0; Address rset_address = ComputeRSetBitPosition(address, offset, &bitmask); return (Memory::uint32_at(rset_address) & bitmask) != 0; +#endif // V8_HOST_ARCH_64_BIT } @@ -194,7 +202,7 @@ bool MemoryAllocator::IsPageInSpace(Page* p, PagedSpace* space) { Page* MemoryAllocator::GetNextPage(Page* p) { ASSERT(p->is_valid()); - int raw_addr = p->opaque_header & ~Page::kPageAlignmentMask; + intptr_t raw_addr = p->opaque_header & ~Page::kPageAlignmentMask; return Page::FromAddress(AddressFrom<Address>(raw_addr)); } @@ -207,7 +215,7 @@ int MemoryAllocator::GetChunkId(Page* p) { void MemoryAllocator::SetNextPage(Page* prev, Page* next) { ASSERT(prev->is_valid()); - int chunk_id = prev->opaque_header & Page::kPageAlignmentMask; + int chunk_id = GetChunkId(prev); ASSERT_PAGE_ALIGNED(next->address()); prev->opaque_header = OffsetFrom(next->address()) | chunk_id; } |