Skip to content

De-std::atomic Span::allocated_.#348

Draft
copybara-service[bot] wants to merge 1 commit into
masterfrom
test_945244330
Draft

De-std::atomic Span::allocated_.#348
copybara-service[bot] wants to merge 1 commit into
masterfrom
test_945244330

Conversation

@copybara-service

@copybara-service copybara-service Bot commented Jul 13, 2026

Copy link
Copy Markdown

De-std::atomic Span::allocated_.

This prevents the compiler from merging redundant load/store operations. This
is especially pronounced on InsertRange, while RemoveRange appears to have
enough memory pressure that we will need to spill anyways.

Since the turndown of the fragmentation profile, we no longer need to keep Span::Allocated() safe for accessing across threads so an ordinary integer will suffice.

@copybara-service copybara-service Bot force-pushed the test_945244330 branch 5 times, most recently from 9594c6b to 77691f2 Compare July 13, 2026 22:51
This prevents the compiler from merging redundant load/store operations.  This
is especially pronounced on InsertRange, while RemoveRange appears to have
enough memory pressure that we will need to spill anyways.

Since the turndown of the fragmentation profile, we no longer need to keep `Span::Allocated()` safe for accessing across threads so an ordinary integer will suffice.

PiperOrigin-RevId: 945244330
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant