[Question] Why does the total value decrease when the "_mi_stats_print" function is executed for each TLD?
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 35/100
- Issue type
- Bug
- Clarity
- Needs clarification
- Activity status
- Stale
- Tech stack
- c
- Domain
- operating-systems
Research direction
Start at the _mi_stats_print entry point and compare its behavior in mimalloc 2.1.2 and 3.0.8. Reproduce repeated per-TLD statistics printing with the provided mi_custom_thread_stats_print_out wrapper, then determine why the reported total decreases and document the relevant version change.
Written by the indexing model from the issue text.
Description
Hi, thank you for your work on this project.
In our proxy server project, which uses mimalloc as the memory manager, we maintain statistics for each TLD using a dedicated structure when the server process runs. We have implemented an interface function that allows us to print stats for each TLD using _mi_stats_print, as shown below. However, as you can see in the attached screenshot, we have observed that the value of "total" decreases when this is done.
void mi_custom_thread_stats_print_out(mi_stats_t* tid_stat, mi_output_fun* out, void* arg) mi_attr_noexcept {
_mi_stats_print(tid_stat, out, arg);
}
This issue did not occur with mimalloc version 2.1.2, but started happening after upgrading to version 3.0.8. Do you have any idea what might be causing this?
For reference, the screenshot only shows the output for the “pssv#1” thread, filtered from the _mi_stats_print results using grep.
- Dominant language
- C
- Stars
- 13.6k
- Forks
- 1.2k
- Avg merge
- 18h 12m
- Merged PRs (30d)
- 20
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from microsoft/mimalloc
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
Maintainers usually reply within 1 day
-
Building mimalloc with `-Wundef` compiler flag logs many warnings on undefined macrosPossibly taken @vstinner claimed this 1 day ago. Open
Difficulty 2/5 1-3 hours Newbie friendliness 64/100
microsoft/mimalloc#1506 · 5 comments ·
Maintainers usually reply within 1 day
-
stale
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
microsoft/mimalloc#1113 · 1 comment ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
microsoft/mimalloc#886 · 4 comments · 1 reaction ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 64/100
microsoft/mimalloc#368 · 1 comment ·
Maintainers usually reply within 1 day
All issues in microsoft/mimalloc
Similar issues
-
needs triage
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
389ds/389-ds-base#8157 ·
Maintainers usually reply within 2 days
-
Difficulty 2/5 1-3 hours Newbie friendliness 67/100
coolsnowwolf/lede#14305 ·
Maintainers usually reply within 1 day
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
Maintainers usually reply within 1 day
-
Needs-Triage
Difficulty 2/5 1-3 hours Newbie friendliness 66/100
Maintainers usually reply within 2 days