GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | |||||||||||||||||||||||||||||||||||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | |||||||||||||||||||||||||||||||||||||||
GeezerVison is showing github.com — gh-159111: Update vendored mimalloc to v2.5.2 by corona10 · Pull Request #159112 · python/cpython Conversation
|
|
🤖 New build scheduled with the buildbot fleet by @corona10 for commit 2649e2b 🤖 Results will be shown at: https://buildbot.python.org/all/#/grid?branch=refs%2Fpull%2F159112%2Fmerge If you want to schedule another build, you need to add the 🔨 test-with-refleak-buildbots label again. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
Upgrade mimalloc from v2.1.2 to v2.5.2 as-is from upstream. v2.1.2: https://github.com/microsoft/mimalloc/releases/tag/v2.1.2 v2.5.2: https://github.com/microsoft/mimalloc/releases/tag/v2.5.2
|
🤖 New build scheduled with the buildbot fleet by @corona10 for commit f81e6c2 🤖 Results will be shown at: https://buildbot.python.org/all/#/grid?branch=refs%2Fpull%2F159112%2Fmerge If you want to schedule another build, you need to add the 🔨 test-with-refleak-buildbots label again. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
@mpage, could you trigger a free-threading benchmark for this change? :) |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
Documentation build overview
85 files changed ·
|
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
🤖 New build scheduled with the buildbot fleet by @corona10 for commit 222601b 🤖 Results will be shown at: https://buildbot.python.org/all/#/grid?branch=refs%2Fpull%2F159112%2Fmerge If you want to schedule another build, you need to add the 🔨 test-with-refleak-buildbots label again. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
I will fix MSAN later: |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
Most of the previous downstream changes were upstreamed in mimalloc v2.1.3 - v2.1.7 (heap tags, _mi_heap_init/_mi_tld_init, MI_PRIM_THREAD_ID, sub-processes, heap walk optimizations, platform fixes) and are dropped. Remaining CPython-specific changes, all marked with a "CPython" comment: - QSBR delayed page freeing for free-threaded builds (pythongh-115103, pythongh-145615): mi_page_t/mi_heap_t fields and _PyMem_mi_* hooks in page.c, heap.c and segment.c. - debug_offset: preserve the first bytes of a PyObject (ob_tid, refcount fields) when filling freed or uninitialized memory in debug builds (pythongh-115491). - Atomic mi_block_t.next loads/stores to avoid TSAN reports (pythongh-129748). - Relax the owning thread assertion in _mi_free_delayed_block for free-threaded builds, since the GC traverses heaps of other threads. - Call _mi_heap_delayed_free_partial() in mi_heap_visit_blocks() (pythongh-112532). - Only count reclaimed pages up to MI_MEDIUM_OBJ_SIZE_MAX as a "right page" in mi_segment_reclaim (pythongh-115103). - Rename the weak _ZSt15get_new_handlerv symbol and disable the mi_is_in_heap_region debug warning. - Zero-initialize _mi_page_empty instead of a positional initializer.
|
🤖 New build scheduled with the buildbot fleet by @corona10 for commit 8b9cb49 🤖 Results will be shown at: https://buildbot.python.org/all/#/grid?branch=refs%2Fpull%2F159112%2Fmerge If you want to schedule another build, you need to add the 🔨 test-with-refleak-buildbots label again. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
@corona10 - Kicked off another run. Fingers crossed this one works. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
Okay benchmark result now looks good to me since there is no significant change Would you like to review this PR? |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
| * Update the bundled `mimalloc library`_ from version 2.1.2 to 2.5.2. | ||
| (Contributed by Donghee Na in :gh:`159111`.) | ||
|
|
||
| .. _mimalloc library: https://github.com/microsoft/mimalloc/ | ||
|
|
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
| * Update the bundled `mimalloc library`_ from version 2.1.2 to 2.5.2. | |
| (Contributed by Donghee Na in :gh:`159111`.) | |
| .. _mimalloc library: https://github.com/microsoft/mimalloc/ |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Because for the main branch, we will target v3.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
cc @DinoV |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
This looks good!
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
|
Thanks @corona10 for the PR 🌮🎉.. I'm working now to backport this PR to: 3.14, 3.15. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
Sorry, @corona10, I could not cleanly backport this to Please backport manually with cherry_picker, see the devguide for more information. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
Sorry, @corona10, I could not cleanly backport this to Please backport manually with cherry_picker, see the devguide for more information. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
…159112) * Update vendored mimalloc to v2.5.2 Upgrade mimalloc from v2.1.2 to v2.5.2 as-is from upstream. v2.1.2: https://github.com/microsoft/mimalloc/releases/tag/v2.1.2 v2.5.2: https://github.com/microsoft/mimalloc/releases/tag/v2.5.2 * Re-apply CPython-specific changes to mimalloc v2.5.2 Most of the previous downstream changes were upstreamed in mimalloc v2.1.3 - v2.1.7 (heap tags, _mi_heap_init/_mi_tld_init, MI_PRIM_THREAD_ID, sub-processes, heap walk optimizations, platform fixes) and are dropped. Remaining CPython-specific changes, all marked with a "CPython" comment: - QSBR delayed page freeing for free-threaded builds (pythongh-115103, pythongh-145615): mi_page_t/mi_heap_t fields and _PyMem_mi_* hooks in page.c, heap.c and segment.c. - debug_offset: preserve the first bytes of a PyObject (ob_tid, refcount fields) when filling freed or uninitialized memory in debug builds (pythongh-115491). - Atomic mi_block_t.next loads/stores to avoid TSAN reports (pythongh-129748). - Relax the owning thread assertion in _mi_free_delayed_block for free-threaded builds, since the GC traverses heaps of other threads. - Call _mi_heap_delayed_free_partial() in mi_heap_visit_blocks() (pythongh-112532). - Only count reclaimed pages up to MI_MEDIUM_OBJ_SIZE_MAX as a "right page" in mi_segment_reclaim (pythongh-115103). - Rename the weak _ZSt15get_new_handlerv symbol and disable the mi_is_in_heap_region debug warning. - Zero-initialize _mi_page_empty instead of a positional initializer. * Update the free-threaded build to mimalloc v2.5.2 changes mimalloc v2.1.4 replaced the list of abandoned segments with per-arena bitmaps and introduced sub-processes (mi_subproc_t) to keep abandoned segments of separate interpreters apart. Use them instead of the CPython-specific mi_abandoned_pool_t: - Each interpreter owns a mi_subproc_t created in init_interpreter(). - tstate_mimalloc_bind() sets tld->segments.subproc and uses the upstream _mi_heap_init() signature. - The GC and sys.getallocatedblocks() visit abandoned segments with _PyMem_mi_visit_abandoned_blocks(), the upstream cursor API without the mi_option_visit_abandoned requirement, while STW. * Update NEWS.d * fix MSAN * fix TSAN * fix test_cext * Disable THP * Address code review * Address code review * Address code review * nit * Address code review * Address code review (cherry picked from commit aff7a2e) Co-authored-by: Donghee Na <[email protected]>
|
GH-160178 is a backport of this pull request to the 3.15 branch. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
GH-160183 is a backport of this pull request to the 3.14 branch. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
Successfully merging this pull request may close these issues.
There was an error while loading. Please reload this page.