Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sorting records are larger than really necessary [CORE4353] #4675

Closed
firebird-issue-importer opened this issue Feb 25, 2014 · 4 comments
Closed

Comments

@firebird-issue-importer

Submitted by: @pavel-zotov

In external sorting (SORT plan), every record being sorted is stored as the sort key plus all the referenced fields plus stream-level information plus padding/alignment. However, the sorting record length is calculated inaccurately, causing redundant bytes to be allocated but never used. This causes the sort blocks to grow more than necessary thus slowing down the operation, especially when number of records being sorted is huge and sort blocks are swapped to disk. In most practical cases, this overhead is relatively small and is unlikely to be more than 5-10%, but in some artificial cases it could be up to 50%.

Commits: fd9f3ee d91fd2e FirebirdSQL/fbt-repository@990dba1 FirebirdSQL/fbt-repository@5416aab

====== Test Details ======

TODO // compare output of mon$memory_usage ?

@firebird-issue-importer
Copy link
Author

firebird-issue-importer commented Feb 25, 2014

Modified by: @dyemanov

reporter: Dmitry Yemanov [ dimitr ] => Pavel Zotov [ tabloid ]

assignee: Dmitry Yemanov [ dimitr ]

@firebird-issue-importer
Copy link
Author

firebird-issue-importer commented Feb 25, 2014

Modified by: @dyemanov

status: Open [ 1 ] => Resolved [ 5 ]

resolution: Fixed [ 1 ]

Fix Version: 2.5.3 [ 10461 ]

Fix Version: 3.0 Beta 1 [ 10332 ]

@firebird-issue-importer
Copy link
Author

firebird-issue-importer commented Jun 1, 2015

Modified by: @pavel-zotov

status: Resolved [ 5 ] => Resolved [ 5 ]

QA Status: Deferred

Test Details: TODO // compare output of mon$memory_usage ?

@firebird-issue-importer
Copy link
Author

firebird-issue-importer commented Sep 22, 2015

Modified by: @pcisar

status: Resolved [ 5 ] => Closed [ 6 ]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment