memtx: fix tuple waste size calculation#11652
Merged
sergepetrenko merged 2 commits intotarantool:masterfrom Jul 16, 2025
Merged
memtx: fix tuple waste size calculation#11652sergepetrenko merged 2 commits intotarantool:masterfrom
sergepetrenko merged 2 commits intotarantool:masterfrom
Conversation
nshy
approved these changes
Jul 11, 2025
Contributor
nshy
left a comment
There was a problem hiding this comment.
Nice patch! Glad to see we now have good waste_size calculations without crutches.
locker
approved these changes
Jul 11, 2025
AArdeev
approved these changes
Jul 15, 2025
d00bb4f to
bdd3471
Compare
bdd3471 to
8afc16b
Compare
* small: drop function declarations without definitions * small: improve real_size calculation in small_alloc_info NO_DOC=submodule bump NO_TEST=submodule bump NO_CHANGELOG=submodule bump
The main part of the fix resides in the `small` submodule, see commit "small: improve real_size calculation in small_alloc_info". Current patch fixes the pointer that is passed to `small_alloc_info()` - it should point to the `memtx_tuple` rather than `tuple`. Also `memtx_tuple` contains `uint32_t version` that had not been accounted before, now these 4 bytes are added to the `header_size`. Closes tarantool#10217 @TarantoolBot document Title: Remove the note regarding `waste_size` from `tuple_object.info()` Product: Tarantool Root document: https://www.tarantool.io/en/doc/latest/reference/reference_lua/box_tuple/info/#box-tuple-info Remove the following note: `waste_size` is provided for reference only and can be inaccurate. Avoid using it for memory usage calculations.
8afc16b to
216d262
Compare
Collaborator
|
Successfully created backport PR for |
Collaborator
|
Successfully created backport PR for |
Collaborator
|
Successfully created backport PR for |
Collaborator
Backport summary
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The main part of the fix resides in the
smallsubmodule, see commit "small: improve real_size calculation in small_alloc_info". Current patch fixes the pointer that is passed tosmall_alloc_info()- it should point to thememtx_tuplerather thantuple. Alsomemtx_tuplecontainsuint32_t versionthat had not been accounted before, now these 4 bytes are added to theheader_size.Closes #10217