Skip to content

Avoid redundant loads, calculations, and branches in ListPushBatch.#361

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

Avoid redundant loads, calculations, and branches in ListPushBatch.#361
copybara-service[bot] wants to merge 1 commit into
masterfrom
test_949140087

Conversation

@copybara-service

Copy link
Copy Markdown

Avoid redundant loads, calculations, and branches in ListPushBatch.

  • We avoid reloading freelist_ and embed_count_ on every object.
  • We hoist the calculation of host to only the empty freelist_ and full
    `embed_count_ cases.
  • We peel off the freelist_ == kListEnd, since this case only needs to be
    handled once on the first element of the batch.

* We avoid reloading `freelist_` and `embed_count_` on every object.
* We hoist the calculation of `host` to only the empty `freelist_` and full
  `embed_count_ cases.
* We peel off the `freelist_ == kListEnd`, since this case only needs to be
  handled once on the first element of the batch.

PiperOrigin-RevId: 949140087
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