| OLD | NEW |
| 1 // Copyright 2006-2008 the V8 project authors. All rights reserved. | 1 // Copyright 2006-2008 the V8 project authors. All rights reserved. |
| 2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
| 3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
| 4 // met: | 4 // met: |
| 5 // | 5 // |
| 6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
| 7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
| 8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
| 9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
| 10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
| (...skipping 212 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 223 #ifdef V8_TARGET_ARCH_X64 | 223 #ifdef V8_TARGET_ARCH_X64 |
| 224 static const int kRSetOffset = 4 * kPointerSize; // Room for four pointers. | 224 static const int kRSetOffset = 4 * kPointerSize; // Room for four pointers. |
| 225 #else | 225 #else |
| 226 static const int kRSetOffset = 0; | 226 static const int kRSetOffset = 0; |
| 227 #endif | 227 #endif |
| 228 // The end offset of the remembered set in a page | 228 // The end offset of the remembered set in a page |
| 229 // (heaps are aligned to pointer size). | 229 // (heaps are aligned to pointer size). |
| 230 static const int kRSetEndOffset = kRSetOffset + kPageSize / kBitsPerPointer; | 230 static const int kRSetEndOffset = kRSetOffset + kPageSize / kBitsPerPointer; |
| 231 | 231 |
| 232 // The start offset of the object area in a page. | 232 // The start offset of the object area in a page. |
| 233 static const int kObjectStartOffset = kRSetEndOffset; | 233 // This needs to be at least (bits per uint32_t) * kBitsPerPointer, |
| 234 // to align start of rset to a uint32_t address. |
| 235 static const int kObjectStartOffset = 256; |
| 234 | 236 |
| 235 // The start offset of the remembered set in a page. | 237 // The start offset of the remembered set in a page. |
| 236 static const int kRSetStartOffset = kRSetOffset + | 238 static const int kRSetStartOffset = kRSetOffset + |
| 237 kObjectStartOffset / kBitsPerPointer; | 239 kObjectStartOffset / kBitsPerPointer; |
| 238 | 240 |
| 239 // Object area size in bytes. | 241 // Object area size in bytes. |
| 240 static const int kObjectAreaSize = kPageSize - kObjectStartOffset; | 242 static const int kObjectAreaSize = kPageSize - kObjectStartOffset; |
| 241 | 243 |
| 242 // Maximum object size that fits in a page. | 244 // Maximum object size that fits in a page. |
| 243 static const int kMaxHeapObjectSize = kObjectAreaSize; | 245 static const int kMaxHeapObjectSize = kObjectAreaSize; |
| (...skipping 1495 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1739 | 1741 |
| 1740 private: | 1742 private: |
| 1741 LargeObjectChunk* current_; | 1743 LargeObjectChunk* current_; |
| 1742 HeapObjectCallback size_func_; | 1744 HeapObjectCallback size_func_; |
| 1743 }; | 1745 }; |
| 1744 | 1746 |
| 1745 | 1747 |
| 1746 } } // namespace v8::internal | 1748 } } // namespace v8::internal |
| 1747 | 1749 |
| 1748 #endif // V8_SPACES_H_ | 1750 #endif // V8_SPACES_H_ |
| OLD | NEW |