Skip to content

rgw/s3vectors: define RadosVectorBucket's destructor out of line - #73088

Merged
yuvalif merged 1 commit into
ceph:mainfrom
mheler:wip-rgw-vector-bucket-destructor
Oct 26, 2026
Merged

yuvalif merged 1 commit into
ceph:mainfrom
mheler:wip-rgw-vector-bucket-destructor

Conversation

@mheler

@mheler mheler commented Oct 26, 2026

Copy link
Copy Markdown
Contributor

Define RadosVectorBucket's destructor out of line, like RadosBucket's. Since #72180 made RadosVectorBucket a subclass of RadosBucket, its inline destructor gets copied into every rgw file that deletes a Bucket, and each copy pulls RadosStore, and with it most of rgw_common, into rgw tests and tools that only need a small part of it.

Fixes: https://tracker.ceph.com/issues/82052

Contribution Guidelines

  • To sign and title your commits, please refer to Submitting Patches to Ceph.

  • If you are submitting a fix for a stable branch (e.g. "quincy"), please refer to Submitting Patches to Ceph - Backports for the proper workflow.

  • When filling out the below checklist, you may click boxes directly in the GitHub web UI. When entering or editing the entire PR message in the GitHub web UI editor, you may also select a checklist item by adding an x between the brackets: [x]. Spaces and capitalization matter when checking off items this way.

Checklist

  • Tracker (select at least one)
    • References tracker ticket
    • Very recent bug; references commit where it was introduced
    • New feature (ticket optional)
    • Doc update (no ticket needed)
    • Code cleanup (no ticket needed)
  • Component impact
    • Affects Dashboard, opened tracker ticket
    • Affects Orchestrator, opened tracker ticket
    • No impact that needs to be tracked
  • Documentation (select at least one)
    • Updates relevant documentation
    • No doc update is appropriate
  • Tests (select at least one)
Show available Jenkins commands

You must only issue one Jenkins command per-comment. Jenkins does not understand
comments with more than one command.

RadosVectorBucket's inline destructor is copied into every rgw file that
deletes a Bucket, and each copy needs RadosStore, so even small rgw
binaries end up linking most of rgw_common.

Define it out of line like RadosBucket's destructor, so it no longer
gets copied.

Assisted-by: Claude Opus 5.5
Signed-off-by: Matthew N. Heler <[email protected]>
@github-actions github-actions Bot added the rgw label Oct 26, 2026
@mheler
mheler marked this pull request as ready for review October 26, 2026 04:03
@mheler
mheler requested a review from a team as a code owner October 26, 2026 04:03
@yuvalif

yuvalif commented Oct 26, 2026

Copy link
Copy Markdown
Contributor

@tchaikov tchaikov left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm.

I built the same tree with and without this change under LTO (-g -O2 -flto=auto -ffat-lto-objects, lancedb ON, 32 threads). About half of the RGW tests and tools stop pulling in the Rust code. For example:

target peak link PSS link time
rgw-policy-check 5.5 -> 0.8 GiB 79 -> 6 s
radosgw-es 5.3 -> 0.8 GiB 77 -> 6 s
ceph_test_rgw_redis_driver 5.4 -> 0.9 GiB 82 -> 7 s

Across the lancedb targets that linked in both builds, links peaking above 4 GiB went from 31 to 15, total peak PSS from 170 to 106 GiB, and total link time from 2595 to 1586 s. radosgw, radosgw-admin, librgw.so and denc-mod-rgw.so still carry it, since they use the rados SAL, so this and #73063 complement each other.

but i am afraid that this alone won't fix jammy: its gcc 12.3 has PR lto/114655, so each remaining RGW link still runs an LTRANS job per thread there. but with half as many heavy links, the burst is less likely to run out of memory.

@yuvalif
yuvalif merged commit c3a0c6f into ceph:main Oct 26, 2026
17 checks passed
@yuvalif yuvalif added the TESTED label Oct 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants