Commit 50a17855 authored by Anton Bikineev's avatar Anton Bikineev Committed by V8 LUCI CQ

cppgc: Reduce the age table back to 1MB

The increase caused a significant PMF regression on Windows. Apparently,
leaving the table in reserved state didn't eliminate the regression. The
CL returns the age size back to 1MB. The followup is to investiage and
fix the regression.

Bug: chromium:1336420
Change-Id: I56542ba4efe0fc8d08d8c5febf758384559a8860
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3758146Reviewed-by: 's avatarMichael Lippautz <mlippautz@chromium.org>
Auto-Submit: Anton Bikineev <bikineev@chromium.org>
Commit-Queue: Anton Bikineev <bikineev@chromium.org>
Cr-Commit-Position: refs/heads/main@{#81705}
parent 1defafa4
...@@ -33,7 +33,7 @@ class HeapBase; ...@@ -33,7 +33,7 @@ class HeapBase;
// regions (cards). Each entry in the table represents generation of the objects // regions (cards). Each entry in the table represents generation of the objects
// that reside on the corresponding card (young, old or mixed). // that reside on the corresponding card (young, old or mixed).
class V8_EXPORT AgeTable final { class V8_EXPORT AgeTable final {
static constexpr size_t kRequiredSize = 8 * api_constants::kMB; static constexpr size_t kRequiredSize = 1 * api_constants::kMB;
static constexpr size_t kAllocationGranularity = static constexpr size_t kAllocationGranularity =
api_constants::kAllocationGranularity; api_constants::kAllocationGranularity;
...@@ -72,7 +72,7 @@ class V8_EXPORT AgeTable final { ...@@ -72,7 +72,7 @@ class V8_EXPORT AgeTable final {
__builtin_ctz(static_cast<uint32_t>(kCardSizeInBytes)); __builtin_ctz(static_cast<uint32_t>(kCardSizeInBytes));
#else //! V8_HAS_BUILTIN_CTZ #else //! V8_HAS_BUILTIN_CTZ
// Hardcode and check with assert. // Hardcode and check with assert.
9; 12;
#endif // !V8_HAS_BUILTIN_CTZ #endif // !V8_HAS_BUILTIN_CTZ
static_assert((1 << kGranularityBits) == kCardSizeInBytes); static_assert((1 << kGranularityBits) == kCardSizeInBytes);
const size_t entry = offset >> kGranularityBits; const size_t entry = offset >> kGranularityBits;
...@@ -83,8 +83,8 @@ class V8_EXPORT AgeTable final { ...@@ -83,8 +83,8 @@ class V8_EXPORT AgeTable final {
std::array<Age, kRequiredSize> table_; std::array<Age, kRequiredSize> table_;
}; };
static_assert(sizeof(AgeTable) == 8 * api_constants::kMB, static_assert(sizeof(AgeTable) == 1 * api_constants::kMB,
"Size of AgeTable is 8MB"); "Size of AgeTable is 1MB");
#endif // CPPGC_YOUNG_GENERATION #endif // CPPGC_YOUNG_GENERATION
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment