cppgc: Optimize allocation by placing GCInfo in separate section [v8/v8 : main]

1 view
Skip to first unread message

chromeperf@appspot.gserviceaccount.com (Gerrit)

unread,
Jun 10, 2026, 9:00:04 AMJun 10
to Anton Bikineev, Hannes Payer, android-bu...@system.gserviceaccount.com, v8-s...@luci-project-accounts.iam.gserviceaccount.com, cbruni...@chromium.org, victorgo...@chromium.org, oilpan-r...@chromium.org, mlippau...@chromium.org
Attention needed from Anton Bikineev

Message from chrom...@appspot.gserviceaccount.com

📍 Job mac-m1_mini_2020-perf/speedometer3 complete.

See results at: https://pinpoint-dot-chromeperf.appspot.com/job/14994d57490000

Open in Gerrit

Related details

Attention is currently required from:
  • Anton Bikineev
Submit Requirements:
  • requirement is not satisfiedCode-Owners
  • requirement is not satisfiedCode-Review
  • requirement is not satisfiedReview-Enforcement
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: v8/v8
Gerrit-Branch: main
Gerrit-Change-Id: I83b5bf36dd8f0d0f469caf3dc8db4eb9464c2250
Gerrit-Change-Number: 7918333
Gerrit-PatchSet: 1
Gerrit-Owner: Anton Bikineev <biki...@chromium.org>
Gerrit-Reviewer: Anton Bikineev <biki...@chromium.org>
Gerrit-CC: Hannes Payer <hpa...@chromium.org>
Gerrit-Attention: Anton Bikineev <biki...@chromium.org>
Gerrit-Comment-Date: Wed, 10 Jun 2026 13:00:00 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: No
unsatisfied_requirement
open
diffy

chromeperf@appspot.gserviceaccount.com (Gerrit)

unread,
Jun 10, 2026, 9:28:26 AMJun 10
to Anton Bikineev, Hannes Payer, android-bu...@system.gserviceaccount.com, v8-s...@luci-project-accounts.iam.gserviceaccount.com, cbruni...@chromium.org, victorgo...@chromium.org, oilpan-r...@chromium.org, mlippau...@chromium.org
Attention needed from Anton Bikineev

Message from chrom...@appspot.gserviceaccount.com

📍 Job mac-m1_mini_2020-perf/speedometer3 complete.

See results at: https://pinpoint-dot-chromeperf.appspot.com/job/11bb134f490000

Open in Gerrit

Related details

Attention is currently required from:
  • Anton Bikineev
Submit Requirements:
  • requirement is not satisfiedCode-Owners
  • requirement is not satisfiedCode-Review
  • requirement is not satisfiedReview-Enforcement
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: v8/v8
Gerrit-Branch: main
Gerrit-Change-Id: I83b5bf36dd8f0d0f469caf3dc8db4eb9464c2250
Gerrit-Change-Number: 7918333
Gerrit-PatchSet: 1
Gerrit-Owner: Anton Bikineev <biki...@chromium.org>
Gerrit-Reviewer: Anton Bikineev <biki...@chromium.org>
Gerrit-CC: Hannes Payer <hpa...@chromium.org>
Gerrit-Attention: Anton Bikineev <biki...@chromium.org>
Gerrit-Comment-Date: Wed, 10 Jun 2026 13:28:23 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: No
unsatisfied_requirement
open
diffy

chromeperf@appspot.gserviceaccount.com (Gerrit)

unread,
Jun 10, 2026, 10:24:04 AMJun 10
to Anton Bikineev, Hannes Payer, android-bu...@system.gserviceaccount.com, v8-s...@luci-project-accounts.iam.gserviceaccount.com, cbruni...@chromium.org, victorgo...@chromium.org, oilpan-r...@chromium.org, mlippau...@chromium.org
Attention needed from Anton Bikineev

Message from chrom...@appspot.gserviceaccount.com

📍 Job mac-m4-mini-perf/speedometer3 complete.

See results at: https://pinpoint-dot-chromeperf.appspot.com/job/127c3508c90000

Open in Gerrit

Related details

Attention is currently required from:
  • Anton Bikineev
Submit Requirements:
  • requirement is not satisfiedCode-Owners
  • requirement is not satisfiedCode-Review
  • requirement is not satisfiedReview-Enforcement
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: v8/v8
Gerrit-Branch: main
Gerrit-Change-Id: I83b5bf36dd8f0d0f469caf3dc8db4eb9464c2250
Gerrit-Change-Number: 7918333
Gerrit-PatchSet: 1
Gerrit-Owner: Anton Bikineev <biki...@chromium.org>
Gerrit-Reviewer: Anton Bikineev <biki...@chromium.org>
Gerrit-CC: Hannes Payer <hpa...@chromium.org>
Gerrit-Attention: Anton Bikineev <biki...@chromium.org>
Gerrit-Comment-Date: Wed, 10 Jun 2026 14:23:59 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: No
unsatisfied_requirement
open
diffy

chromeperf@appspot.gserviceaccount.com (Gerrit)

unread,
Jun 10, 2026, 9:09:50 PMJun 10
to Anton Bikineev, Hannes Payer, android-bu...@system.gserviceaccount.com, v8-s...@luci-project-accounts.iam.gserviceaccount.com, cbruni...@chromium.org, victorgo...@chromium.org, oilpan-r...@chromium.org, mlippau...@chromium.org
Attention needed from Anton Bikineev

Message from chrom...@appspot.gserviceaccount.com

📍 Job mac-m1_mini_2020-perf/speedometer3.crossbench complete.

See results at: https://pinpoint-dot-chromeperf.appspot.com/job/14938f7cc90000

Open in Gerrit

Related details

Attention is currently required from:
  • Anton Bikineev
Submit Requirements:
  • requirement is not satisfiedCode-Owners
  • requirement is not satisfiedCode-Review
  • requirement is not satisfiedReview-Enforcement
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: v8/v8
Gerrit-Branch: main
Gerrit-Change-Id: I83b5bf36dd8f0d0f469caf3dc8db4eb9464c2250
Gerrit-Change-Number: 7918333
Gerrit-PatchSet: 2
Gerrit-Comment-Date: Thu, 11 Jun 2026 01:09:47 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: No
unsatisfied_requirement
open
diffy

chromeperf@appspot.gserviceaccount.com (Gerrit)

unread,
Jun 10, 2026, 9:44:47 PMJun 10
to Anton Bikineev, Hannes Payer, android-bu...@system.gserviceaccount.com, v8-s...@luci-project-accounts.iam.gserviceaccount.com, cbruni...@chromium.org, victorgo...@chromium.org, oilpan-r...@chromium.org, mlippau...@chromium.org
Attention needed from Anton Bikineev

Message from chrom...@appspot.gserviceaccount.com

📍 Job mac-m4-mini-perf/speedometer3.crossbench complete.

See results at: https://pinpoint-dot-chromeperf.appspot.com/job/10b0c36cc90000

Open in Gerrit

Related details

Attention is currently required from:
  • Anton Bikineev
Submit Requirements:
  • requirement is not satisfiedCode-Owners
  • requirement is not satisfiedCode-Review
  • requirement is not satisfiedReview-Enforcement
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: v8/v8
Gerrit-Branch: main
Gerrit-Change-Id: I83b5bf36dd8f0d0f469caf3dc8db4eb9464c2250
Gerrit-Change-Number: 7918333
Gerrit-PatchSet: 2
Gerrit-Owner: Anton Bikineev <biki...@chromium.org>
Gerrit-Reviewer: Anton Bikineev <biki...@chromium.org>
Gerrit-CC: Hannes Payer <hpa...@chromium.org>
Gerrit-Attention: Anton Bikineev <biki...@chromium.org>
Gerrit-Comment-Date: Thu, 11 Jun 2026 01:44:44 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: No
unsatisfied_requirement
open
diffy

Anton Bikineev (Gerrit)

unread,
Jun 11, 2026, 8:50:50 AMJun 11
to Michael Lippautz, chrom...@appspot.gserviceaccount.com, Hannes Payer, android-bu...@system.gserviceaccount.com, v8-s...@luci-project-accounts.iam.gserviceaccount.com, cbruni...@chromium.org, victorgo...@chromium.org, oilpan-r...@chromium.org, mlippau...@chromium.org
Attention needed from Michael Lippautz

Anton Bikineev added 1 comment

Patchset-level comments
File-level comment, Patchset 7 (Latest):
Anton Bikineev . resolved

ptal, should be ready now

Open in Gerrit

Related details

Attention is currently required from:
  • Michael Lippautz
Submit Requirements:
  • requirement is not satisfiedCode-Owners
  • requirement is not satisfiedCode-Review
  • requirement is not satisfiedReview-Enforcement
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: v8/v8
Gerrit-Branch: main
Gerrit-Change-Id: I83b5bf36dd8f0d0f469caf3dc8db4eb9464c2250
Gerrit-Change-Number: 7918333
Gerrit-PatchSet: 7
Gerrit-Owner: Anton Bikineev <biki...@chromium.org>
Gerrit-Reviewer: Anton Bikineev <biki...@chromium.org>
Gerrit-Reviewer: Michael Lippautz <mlip...@chromium.org>
Gerrit-Attention: Michael Lippautz <mlip...@chromium.org>
Gerrit-Comment-Date: Thu, 11 Jun 2026 12:50:46 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
unsatisfied_requirement
open
diffy

Michael Lippautz (Gerrit)

unread,
Jun 11, 2026, 10:27:17 AMJun 11
to Anton Bikineev, chrom...@appspot.gserviceaccount.com, Hannes Payer, android-bu...@system.gserviceaccount.com, v8-s...@luci-project-accounts.iam.gserviceaccount.com, cbruni...@chromium.org, victorgo...@chromium.org, oilpan-r...@chromium.org, mlippau...@chromium.org
Attention needed from Anton Bikineev

Michael Lippautz added 1 comment

File test/unittests/heap/cppgc/gc-info-unittest.cc
Line 5, Patchset 7 (Latest):#if !defined(CPPGC_ENABLE_OBJECT_SECTION_GCINFO)
Michael Lippautz . unresolved

High-level comment: Can we refactor this in a way that we can keep testing the table even in this configuration (to be able to easily switch) and change the top-level dispatch somehow that we use the segment?

Open in Gerrit

Related details

Attention is currently required from:
  • Anton Bikineev
Submit Requirements:
    • requirement is not satisfiedCode-Owners
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    • requirement is not satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: v8/v8
    Gerrit-Branch: main
    Gerrit-Change-Id: I83b5bf36dd8f0d0f469caf3dc8db4eb9464c2250
    Gerrit-Change-Number: 7918333
    Gerrit-PatchSet: 7
    Gerrit-Owner: Anton Bikineev <biki...@chromium.org>
    Gerrit-Reviewer: Anton Bikineev <biki...@chromium.org>
    Gerrit-Reviewer: Michael Lippautz <mlip...@chromium.org>
    Gerrit-CC: Hannes Payer <hpa...@chromium.org>
    Gerrit-Attention: Anton Bikineev <biki...@chromium.org>
    Gerrit-Comment-Date: Thu, 11 Jun 2026 14:27:13 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    unsatisfied_requirement
    open
    diffy

    Anton Bikineev (Gerrit)

    unread,
    Jun 11, 2026, 12:04:21 PMJun 11
    to Michael Lippautz, chrom...@appspot.gserviceaccount.com, Hannes Payer, android-bu...@system.gserviceaccount.com, v8-s...@luci-project-accounts.iam.gserviceaccount.com, cbruni...@chromium.org, victorgo...@chromium.org, oilpan-r...@chromium.org, mlippau...@chromium.org
    Attention needed from Michael Lippautz

    Anton Bikineev added 1 comment

    File test/unittests/heap/cppgc/gc-info-unittest.cc
    Line 5, Patchset 7 (Latest):#if !defined(CPPGC_ENABLE_OBJECT_SECTION_GCINFO)
    Michael Lippautz . unresolved

    High-level comment: Can we refactor this in a way that we can keep testing the table even in this configuration (to be able to easily switch) and change the top-level dispatch somehow that we use the segment?

    Anton Bikineev

    I don't like conceptually having the table in the configuration with the section, I think it can be misleading. Having the table behind ifdef gaurds IMO makes it clear that the table is not used in this configuration. We still test the table on 32-bit and Windows.

    change the top-level dispatch somehow that we use the segment?

    I don't follow. We dispatch in GCInfoTrait (in API) and keep the GCInfoTable behind it. I don't think we want to move the table to API.

    I kept the GCInfoTrait tests and added some section specific ones.

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Michael Lippautz
    Submit Requirements:
    • requirement is not satisfiedCode-Owners
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    • requirement is not satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: v8/v8
    Gerrit-Branch: main
    Gerrit-Change-Id: I83b5bf36dd8f0d0f469caf3dc8db4eb9464c2250
    Gerrit-Change-Number: 7918333
    Gerrit-PatchSet: 7
    Gerrit-Owner: Anton Bikineev <biki...@chromium.org>
    Gerrit-Reviewer: Anton Bikineev <biki...@chromium.org>
    Gerrit-Reviewer: Michael Lippautz <mlip...@chromium.org>
    Gerrit-CC: Hannes Payer <hpa...@chromium.org>
    Gerrit-Attention: Michael Lippautz <mlip...@chromium.org>
    Gerrit-Comment-Date: Thu, 11 Jun 2026 16:04:15 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    Comment-In-Reply-To: Michael Lippautz <mlip...@chromium.org>
    unsatisfied_requirement
    open
    diffy

    Michael Lippautz (Gerrit)

    unread,
    Jun 11, 2026, 12:32:24 PMJun 11
    to Anton Bikineev, chrom...@appspot.gserviceaccount.com, Hannes Payer, android-bu...@system.gserviceaccount.com, v8-s...@luci-project-accounts.iam.gserviceaccount.com, cbruni...@chromium.org, victorgo...@chromium.org, oilpan-r...@chromium.org, mlippau...@chromium.org
    Attention needed from Anton Bikineev

    Michael Lippautz added 3 comments

    File include/cppgc/internal/gc-info.h
    Line 36, Patchset 8 (Latest):struct V8_EXPORT EnsureGCInfoIndexTrait final {
    Michael Lippautz . unresolved

    This trait should also be ifdef'ed away?

    Can we move this below in an #else branch?

    File src/heap/cppgc/gc-info-table.h
    Line 90, Patchset 8 (Latest):class V8_EXPORT GlobalGCInfoTable final {
    Michael Lippautz . unresolved

    I keep on wondering whethere the global table is a good abstraction for version where the info is in the elf section. I realize it's a global table but the split between trait and GlobalGCInfoTable seems a bit weird.

    Mostly wondering because that would then allow to completely ifdef away all the table stuff for the section version.

    File test/unittests/heap/cppgc/gc-info-unittest.cc
    Line 5, Patchset 7:#if !defined(CPPGC_ENABLE_OBJECT_SECTION_GCINFO)
    Michael Lippautz . resolved

    High-level comment: Can we refactor this in a way that we can keep testing the table even in this configuration (to be able to easily switch) and change the top-level dispatch somehow that we use the segment?

    Anton Bikineev

    I don't like conceptually having the table in the configuration with the section, I think it can be misleading. Having the table behind ifdef gaurds IMO makes it clear that the table is not used in this configuration. We still test the table on 32-bit and Windows.

    change the top-level dispatch somehow that we use the segment?

    I don't follow. We dispatch in GCInfoTrait (in API) and keep the GCInfoTable behind it. I don't think we want to move the table to API.

    I kept the GCInfoTrait tests and added some section specific ones.

    Michael Lippautz

    Okay, fair enough. I was worried ab it about test coverage but at least for now we also have component builds to test this on e.g. Linux.

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Anton Bikineev
    Submit Requirements:
    • requirement is not satisfiedCode-Owners
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    • requirement is not satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: v8/v8
    Gerrit-Branch: main
    Gerrit-Change-Id: I83b5bf36dd8f0d0f469caf3dc8db4eb9464c2250
    Gerrit-Change-Number: 7918333
    Gerrit-PatchSet: 8
    Gerrit-Attention: Anton Bikineev <biki...@chromium.org>
    Gerrit-Comment-Date: Thu, 11 Jun 2026 16:30:42 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    Comment-In-Reply-To: Michael Lippautz <mlip...@chromium.org>
    Comment-In-Reply-To: Anton Bikineev <biki...@chromium.org>
    unsatisfied_requirement
    open
    diffy

    Anton Bikineev (Gerrit)

    unread,
    Jun 11, 2026, 1:36:02 PMJun 11
    to Michael Lippautz, chrom...@appspot.gserviceaccount.com, Hannes Payer, android-bu...@system.gserviceaccount.com, v8-s...@luci-project-accounts.iam.gserviceaccount.com, cbruni...@chromium.org, victorgo...@chromium.org, oilpan-r...@chromium.org, mlippau...@chromium.org
    Attention needed from Michael Lippautz

    Anton Bikineev added 2 comments

    File include/cppgc/internal/gc-info.h
    Line 36, Patchset 8:struct V8_EXPORT EnsureGCInfoIndexTrait final {
    Michael Lippautz . resolved

    This trait should also be ifdef'ed away?

    Can we move this below in an #else branch?

    Anton Bikineev

    Good point, done

    File src/heap/cppgc/gc-info-table.h
    Line 90, Patchset 8:class V8_EXPORT GlobalGCInfoTable final {
    Michael Lippautz . unresolved

    I keep on wondering whethere the global table is a good abstraction for version where the info is in the elf section. I realize it's a global table but the split between trait and GlobalGCInfoTable seems a bit weird.

    Mostly wondering because that would then allow to completely ifdef away all the table stuff for the section version.

    Anton Bikineev

    We would still have ifdefs for these two approaches - notice that we don't even access the "table" with the section approach, we merely compute the diff between gcinfo and the start of the section.

    Generally I agree that this abstraction could work for both approaches. You can think of the section approach and mmaping as two different strategies for the table allocation. I don't think, however, that this should be part of this CL, tbh.

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Michael Lippautz
    Submit Requirements:
    • requirement is not satisfiedCode-Owners
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    • requirement is not satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: v8/v8
    Gerrit-Branch: main
    Gerrit-Change-Id: I83b5bf36dd8f0d0f469caf3dc8db4eb9464c2250
    Gerrit-Change-Number: 7918333
    Gerrit-PatchSet: 8
    Gerrit-Owner: Anton Bikineev <biki...@chromium.org>
    Gerrit-Reviewer: Anton Bikineev <biki...@chromium.org>
    Gerrit-Reviewer: Michael Lippautz <mlip...@chromium.org>
    Gerrit-CC: Hannes Payer <hpa...@chromium.org>
    Gerrit-Attention: Michael Lippautz <mlip...@chromium.org>
    Gerrit-Comment-Date: Thu, 11 Jun 2026 17:35:56 +0000
    unsatisfied_requirement
    open
    diffy

    Michael Lippautz (Gerrit)

    unread,
    Jun 11, 2026, 1:53:27 PMJun 11
    to Anton Bikineev, chrom...@appspot.gserviceaccount.com, Hannes Payer, android-bu...@system.gserviceaccount.com, v8-s...@luci-project-accounts.iam.gserviceaccount.com, cbruni...@chromium.org, victorgo...@chromium.org, oilpan-r...@chromium.org, mlippau...@chromium.org
    Attention needed from Anton Bikineev

    Michael Lippautz added 1 comment

    File src/heap/cppgc/gc-info-table.h
    Line 90, Patchset 8:class V8_EXPORT GlobalGCInfoTable final {
    Michael Lippautz . unresolved

    I keep on wondering whethere the global table is a good abstraction for version where the info is in the elf section. I realize it's a global table but the split between trait and GlobalGCInfoTable seems a bit weird.

    Mostly wondering because that would then allow to completely ifdef away all the table stuff for the section version.

    Anton Bikineev

    We would still have ifdefs for these two approaches - notice that we don't even access the "table" with the section approach, we merely compute the diff between gcinfo and the start of the section.

    Generally I agree that this abstraction could work for both approaches. You can think of the section approach and mmaping as two different strategies for the table allocation. I don't think, however, that this should be part of this CL, tbh.

    Michael Lippautz

    We would still have ifdefs for these two approaches - notice that we don't even access the "table" with the section approach, we merely compute the diff between gcinfo and the start of the section.

    That's why I wondered if we should use the `GlobalGCInfoTable` at all with the sections.

    Basically we use `__start_gc_info_section` in the trait and the table which I find confusing and hard to follow.

    Conceptually `__start_gc_info_section` feels like a global table (nice!) which is why we should have it there. The trait uses it as well though which seems impossible to fix? Maybe if we forward to a `GCGlobalInfoTable::EnsureGCInfoIndex<T>` to instantiate the entry there?

    I am not against this CL at all but I find it a bit hard to navigate with the 2 completely different approaches which is why I am trying to find clear entry points.

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Anton Bikineev
    Submit Requirements:
    • requirement is not satisfiedCode-Owners
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    • requirement is not satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: v8/v8
    Gerrit-Branch: main
    Gerrit-Change-Id: I83b5bf36dd8f0d0f469caf3dc8db4eb9464c2250
    Gerrit-Change-Number: 7918333
    Gerrit-PatchSet: 9
    Gerrit-Attention: Anton Bikineev <biki...@chromium.org>
    Gerrit-Comment-Date: Thu, 11 Jun 2026 17:53:23 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    Comment-In-Reply-To: Michael Lippautz <mlip...@chromium.org>
    Comment-In-Reply-To: Anton Bikineev <biki...@chromium.org>
    unsatisfied_requirement
    open
    diffy

    Anton Bikineev (Gerrit)

    unread,
    Jun 11, 2026, 3:09:01 PMJun 11
    to Michael Lippautz, chrom...@appspot.gserviceaccount.com, Hannes Payer, android-bu...@system.gserviceaccount.com, v8-s...@luci-project-accounts.iam.gserviceaccount.com, cbruni...@chromium.org, victorgo...@chromium.org, oilpan-r...@chromium.org, mlippau...@chromium.org
    Attention needed from Michael Lippautz

    Anton Bikineev added 1 comment

    File src/heap/cppgc/gc-info-table.h
    Line 90, Patchset 8:class V8_EXPORT GlobalGCInfoTable final {
    Michael Lippautz . unresolved

    I keep on wondering whethere the global table is a good abstraction for version where the info is in the elf section. I realize it's a global table but the split between trait and GlobalGCInfoTable seems a bit weird.

    Mostly wondering because that would then allow to completely ifdef away all the table stuff for the section version.

    Anton Bikineev

    We would still have ifdefs for these two approaches - notice that we don't even access the "table" with the section approach, we merely compute the diff between gcinfo and the start of the section.

    Generally I agree that this abstraction could work for both approaches. You can think of the section approach and mmaping as two different strategies for the table allocation. I don't think, however, that this should be part of this CL, tbh.

    Michael Lippautz

    We would still have ifdefs for these two approaches - notice that we don't even access the "table" with the section approach, we merely compute the diff between gcinfo and the start of the section.

    That's why I wondered if we should use the `GlobalGCInfoTable` at all with the sections.

    Basically we use `__start_gc_info_section` in the trait and the table which I find confusing and hard to follow.

    Conceptually `__start_gc_info_section` feels like a global table (nice!) which is why we should have it there. The trait uses it as well though which seems impossible to fix? Maybe if we forward to a `GCGlobalInfoTable::EnsureGCInfoIndex<T>` to instantiate the entry there?

    I am not against this CL at all but I find it a bit hard to navigate with the 2 completely different approaches which is why I am trying to find clear entry points.

    Anton Bikineev

    EnsureGCInfoIndex crosses the API, so the type is not available there - the instantantion should happen on the API side. For that we either move GlobalGCInfoTable there, or use some indirection that is called from both the trait and GlobalGCInfoTable. What do you think to wrap the functionality into a class, like GCInfoTableSection?

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Michael Lippautz
    Submit Requirements:
    • requirement is not satisfiedCode-Owners
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    • requirement is not satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: v8/v8
    Gerrit-Branch: main
    Gerrit-Change-Id: I83b5bf36dd8f0d0f469caf3dc8db4eb9464c2250
    Gerrit-Change-Number: 7918333
    Gerrit-PatchSet: 9
    Gerrit-Owner: Anton Bikineev <biki...@chromium.org>
    Gerrit-Reviewer: Anton Bikineev <biki...@chromium.org>
    Gerrit-Reviewer: Michael Lippautz <mlip...@chromium.org>
    Gerrit-CC: Hannes Payer <hpa...@chromium.org>
    Gerrit-Attention: Michael Lippautz <mlip...@chromium.org>
    Gerrit-Comment-Date: Thu, 11 Jun 2026 19:08:56 +0000
    unsatisfied_requirement
    open
    diffy

    Anton Bikineev (Gerrit)

    unread,
    Jun 11, 2026, 3:13:28 PMJun 11
    to Michael Lippautz, chrom...@appspot.gserviceaccount.com, Hannes Payer, android-bu...@system.gserviceaccount.com, v8-s...@luci-project-accounts.iam.gserviceaccount.com, cbruni...@chromium.org, victorgo...@chromium.org, oilpan-r...@chromium.org, mlippau...@chromium.org
    Attention needed from Michael Lippautz

    Anton Bikineev added 1 comment

    File src/heap/cppgc/gc-info-table.h
    Line 90, Patchset 8:class V8_EXPORT GlobalGCInfoTable final {
    Michael Lippautz . unresolved

    I keep on wondering whethere the global table is a good abstraction for version where the info is in the elf section. I realize it's a global table but the split between trait and GlobalGCInfoTable seems a bit weird.

    Mostly wondering because that would then allow to completely ifdef away all the table stuff for the section version.

    Anton Bikineev

    We would still have ifdefs for these two approaches - notice that we don't even access the "table" with the section approach, we merely compute the diff between gcinfo and the start of the section.

    Generally I agree that this abstraction could work for both approaches. You can think of the section approach and mmaping as two different strategies for the table allocation. I don't think, however, that this should be part of this CL, tbh.

    Michael Lippautz

    We would still have ifdefs for these two approaches - notice that we don't even access the "table" with the section approach, we merely compute the diff between gcinfo and the start of the section.

    That's why I wondered if we should use the `GlobalGCInfoTable` at all with the sections.

    Basically we use `__start_gc_info_section` in the trait and the table which I find confusing and hard to follow.

    Conceptually `__start_gc_info_section` feels like a global table (nice!) which is why we should have it there. The trait uses it as well though which seems impossible to fix? Maybe if we forward to a `GCGlobalInfoTable::EnsureGCInfoIndex<T>` to instantiate the entry there?

    I am not against this CL at all but I find it a bit hard to navigate with the 2 completely different approaches which is why I am trying to find clear entry points.

    Anton Bikineev

    EnsureGCInfoIndex crosses the API, so the type is not available there - the instantantion should happen on the API side. For that we either move GlobalGCInfoTable there, or use some indirection that is called from both the trait and GlobalGCInfoTable. What do you think to wrap the functionality into a class, like GCInfoTableSection?

    Anton Bikineev

    (wrapped the whole __start_gc_info_section operations in the GCInfoTableSection class)

    Gerrit-Comment-Date: Thu, 11 Jun 2026 19:13:24 +0000
    unsatisfied_requirement
    open
    diffy

    Michael Lippautz (Gerrit)

    unread,
    Jun 12, 2026, 4:50:05 AMJun 12
    to Anton Bikineev, chrom...@appspot.gserviceaccount.com, Hannes Payer, android-bu...@system.gserviceaccount.com, v8-s...@luci-project-accounts.iam.gserviceaccount.com, cbruni...@chromium.org, victorgo...@chromium.org, oilpan-r...@chromium.org, mlippau...@chromium.org
    Attention needed from Anton Bikineev

    Michael Lippautz voted and added 3 comments

    Votes added by Michael Lippautz

    Code-Review+1

    3 comments

    Patchset-level comments
    File-level comment, Patchset 10 (Latest):
    Michael Lippautz . resolved

    lgtm, thanks for refactoring. I think this is now much better

    File include/cppgc/internal/gc-info.h
    Line 75, Patchset 10 (Latest):inline HeapObjectName GetHiddenName(
    Michael Lippautz . unresolved

    This should probably go outside as it's unrelated :)

    File src/heap/cppgc/gc-info-table.h
    Line 90, Patchset 8:class V8_EXPORT GlobalGCInfoTable final {
    Michael Lippautz . resolved

    I keep on wondering whethere the global table is a good abstraction for version where the info is in the elf section. I realize it's a global table but the split between trait and GlobalGCInfoTable seems a bit weird.

    Mostly wondering because that would then allow to completely ifdef away all the table stuff for the section version.

    Anton Bikineev

    We would still have ifdefs for these two approaches - notice that we don't even access the "table" with the section approach, we merely compute the diff between gcinfo and the start of the section.

    Generally I agree that this abstraction could work for both approaches. You can think of the section approach and mmaping as two different strategies for the table allocation. I don't think, however, that this should be part of this CL, tbh.

    Michael Lippautz

    We would still have ifdefs for these two approaches - notice that we don't even access the "table" with the section approach, we merely compute the diff between gcinfo and the start of the section.

    That's why I wondered if we should use the `GlobalGCInfoTable` at all with the sections.

    Basically we use `__start_gc_info_section` in the trait and the table which I find confusing and hard to follow.

    Conceptually `__start_gc_info_section` feels like a global table (nice!) which is why we should have it there. The trait uses it as well though which seems impossible to fix? Maybe if we forward to a `GCGlobalInfoTable::EnsureGCInfoIndex<T>` to instantiate the entry there?

    I am not against this CL at all but I find it a bit hard to navigate with the 2 completely different approaches which is why I am trying to find clear entry points.

    Anton Bikineev

    EnsureGCInfoIndex crosses the API, so the type is not available there - the instantantion should happen on the API side. For that we either move GlobalGCInfoTable there, or use some indirection that is called from both the trait and GlobalGCInfoTable. What do you think to wrap the functionality into a class, like GCInfoTableSection?

    Anton Bikineev

    (wrapped the whole __start_gc_info_section operations in the GCInfoTableSection class)

    Michael Lippautz

    Yeah, I really like that! Thanks!

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Anton Bikineev
    Submit Requirements:
    • requirement satisfiedCode-Owners
    • requirement satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    • requirement satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: v8/v8
    Gerrit-Branch: main
    Gerrit-Change-Id: I83b5bf36dd8f0d0f469caf3dc8db4eb9464c2250
    Gerrit-Change-Number: 7918333
    Gerrit-PatchSet: 10
    Gerrit-Attention: Anton Bikineev <biki...@chromium.org>
    Gerrit-Comment-Date: Fri, 12 Jun 2026 08:50:01 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: Yes
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Anton Bikineev (Gerrit)

    unread,
    Jun 12, 2026, 5:01:42 AMJun 12
    to Michael Lippautz, chrom...@appspot.gserviceaccount.com, Hannes Payer, android-bu...@system.gserviceaccount.com, v8-s...@luci-project-accounts.iam.gserviceaccount.com, cbruni...@chromium.org, victorgo...@chromium.org, oilpan-r...@chromium.org, mlippau...@chromium.org

    Anton Bikineev added 2 comments

    Patchset-level comments
    File-level comment, Patchset 11 (Latest):
    Anton Bikineev . resolved

    Thanks for taking a look!

    File include/cppgc/internal/gc-info.h
    Line 75, Patchset 10:inline HeapObjectName GetHiddenName(
    Michael Lippautz . resolved

    This should probably go outside as it's unrelated :)

    Anton Bikineev

    Done

    Open in Gerrit

    Related details

    Attention set is empty
    Submit Requirements:
      • requirement satisfiedCode-Owners
      • requirement satisfiedCode-Review
      • requirement satisfiedReview-Enforcement
      Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
      Gerrit-MessageType: comment
      Gerrit-Project: v8/v8
      Gerrit-Branch: main
      Gerrit-Change-Id: I83b5bf36dd8f0d0f469caf3dc8db4eb9464c2250
      Gerrit-Change-Number: 7918333
      Gerrit-PatchSet: 11
      Gerrit-Comment-Date: Fri, 12 Jun 2026 09:01:37 +0000
      satisfied_requirement
      open
      diffy

      Anton Bikineev (Gerrit)

      unread,
      Jun 12, 2026, 5:16:41 AMJun 12
      to Michael Lippautz, chrom...@appspot.gserviceaccount.com, Hannes Payer, android-bu...@system.gserviceaccount.com, v8-s...@luci-project-accounts.iam.gserviceaccount.com, cbruni...@chromium.org, victorgo...@chromium.org, oilpan-r...@chromium.org, mlippau...@chromium.org

      Anton Bikineev voted Commit-Queue+2

      Commit-Queue+2
      Open in Gerrit

      Related details

      Attention set is empty
      Submit Requirements:
      • requirement satisfiedCode-Owners
      • requirement satisfiedCode-Review
      • requirement satisfiedReview-Enforcement
      Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
      Gerrit-MessageType: comment
      Gerrit-Project: v8/v8
      Gerrit-Branch: main
      Gerrit-Change-Id: I83b5bf36dd8f0d0f469caf3dc8db4eb9464c2250
      Gerrit-Change-Number: 7918333
      Gerrit-PatchSet: 11
      Gerrit-Owner: Anton Bikineev <biki...@chromium.org>
      Gerrit-Reviewer: Anton Bikineev <biki...@chromium.org>
      Gerrit-Reviewer: Michael Lippautz <mlip...@chromium.org>
      Gerrit-CC: Hannes Payer <hpa...@chromium.org>
      Gerrit-Comment-Date: Fri, 12 Jun 2026 09:16:37 +0000
      Gerrit-HasComments: No
      Gerrit-Has-Labels: Yes
      satisfied_requirement
      open
      diffy

      v8-scoped@luci-project-accounts.iam.gserviceaccount.com (Gerrit)

      unread,
      Jun 12, 2026, 6:53:59 AMJun 12
      to Anton Bikineev, Michael Lippautz, chrom...@appspot.gserviceaccount.com, Hannes Payer, android-bu...@system.gserviceaccount.com, cbruni...@chromium.org, victorgo...@chromium.org, oilpan-r...@chromium.org, mlippau...@chromium.org

      v8-s...@luci-project-accounts.iam.gserviceaccount.com submitted the change with unreviewed changes

      Unreviewed changes

      10 is the latest approved patch-set.
      The change was submitted with unreviewed changes in the following files:

      ```
      The name of the file: src/heap/cppgc/gc-info.cc
      Insertions: 0, Deletions: 11.

      @@ -11,17 +11,6 @@

      namespace cppgc::internal {

      -namespace {
      -
      -HeapObjectName GetHiddenName(
      - const void*, HeapObjectNameForUnnamedObject name_retrieval_mode) {
      - return {
      - NameProvider::kHiddenName,
      - name_retrieval_mode == HeapObjectNameForUnnamedObject::kUseHiddenName};
      -}
      -
      -} // namespace
      -
      // static
      GCInfoIndex EnsureGCInfoIndexTrait::EnsureGCInfoIndex(
      std::atomic<GCInfoIndex>& registered_index, TraceCallback trace_callback,
      ```
      ```
      The name of the file: include/cppgc/internal/gc-info.h
      Insertions: 9, Deletions: 11.

      @@ -15,8 +15,7 @@
      #include "cppgc/trace-trait.h"
      #include "v8config.h" // NOLINT(build/include_directory)

      -namespace cppgc {
      -namespace internal {
      +namespace cppgc::internal {

      using GCInfoIndex = uint16_t;
      static constexpr GCInfoIndex kMaxGCInfoIndex = 1 << 14;
      @@ -33,6 +32,13 @@
      size_t padding = 0;
      };

      +inline HeapObjectName GetHiddenName(
      + const void*, HeapObjectNameForUnnamedObject name_retrieval_mode) {
      + return {
      + NameProvider::kHiddenName,
      + name_retrieval_mode == HeapObjectNameForUnnamedObject::kUseHiddenName};
      +}
      +
      #if defined(CPPGC_ENABLE_OBJECT_SECTION_GCINFO)

      #if defined(__APPLE__)
      @@ -72,13 +78,6 @@
      }
      };

      -inline HeapObjectName GetHiddenName(
      - const void*, HeapObjectNameForUnnamedObject name_retrieval_mode) {
      - return {
      - NameProvider::kHiddenName,
      - name_retrieval_mode == HeapObjectNameForUnnamedObject::kUseHiddenName};
      -}
      -
      #else // defined(CPPGC_ENABLE_OBJECT_SECTION_GCINFO)

      struct V8_EXPORT EnsureGCInfoIndexTrait final {
      @@ -222,7 +221,6 @@
      NameTrait<T>::HasNonHiddenName() ? NameTrait<T>::GetName : GetHiddenName);
      #endif // defined(CPPGC_ENABLE_OBJECT_SECTION_GCINFO)

      -} // namespace internal
      -} // namespace cppgc
      +} // namespace cppgc::internal

      #endif // INCLUDE_CPPGC_INTERNAL_GC_INFO_H_
      ```

      Change information

      Commit message:
      cppgc: Optimize allocation by placing GCInfo in separate section

      Place GCInfo objects into a separate section (`gc_info_section` or
      `__DATA,gc_info_section`) and compute the index directly as an offset
      from the start of the section. This avoids the overhead of dynamic
      registration and checking on allocation. This also eliminates the need
      for `GCInfoTable` when active.

      The optimization is enabled by default on desktop (Linux and macOS)
      under the `cppgc_enable_object_section_gcinfo` GN flag for non-component
      builds.

      ELF and MachO platforms are supported.

      TAG=agy
      Change-Id: I83b5bf36dd8f0d0f469caf3dc8db4eb9464c2250
      Bug: 522693606
      Reviewed-by: Michael Lippautz <mlip...@chromium.org>
      Commit-Queue: Anton Bikineev <biki...@chromium.org>
      Cr-Commit-Position: refs/heads/main@{#107939}
      Files:
      • M BUILD.bazel
      • M BUILD.gn
      • M gni/v8.gni
      • M include/cppgc/internal/gc-info.h
      • M src/heap/cppgc/gc-info-table.cc
      • M src/heap/cppgc/gc-info-table.h
      • M src/heap/cppgc/gc-info.cc
      • M src/heap/cppgc/heap-object-header.h
      • M test/unittests/heap/cppgc/gc-info-unittest.cc
      • M test/unittests/heap/cppgc/heap-object-header-unittest.cc
      Change size: M
      Delta: 10 files changed, 139 insertions(+), 32 deletions(-)
      Branch: refs/heads/main
      Submit Requirements:
      • requirement satisfiedCode-Review: +1 by Michael Lippautz
      Open in Gerrit
      Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
      Gerrit-MessageType: merged
      Gerrit-Project: v8/v8
      Gerrit-Branch: main
      Gerrit-Change-Id: I83b5bf36dd8f0d0f469caf3dc8db4eb9464c2250
      Gerrit-Change-Number: 7918333
      Gerrit-PatchSet: 12
      Gerrit-Owner: Anton Bikineev <biki...@chromium.org>
      Gerrit-Reviewer: Anton Bikineev <biki...@chromium.org>
      Gerrit-Reviewer: Michael Lippautz <mlip...@chromium.org>
      open
      diffy
      satisfied_requirement
      Reply all
      Reply to author
      Forward
      0 new messages