Skip to content

Re-enable psutil and numba for py3.14#200

Open
aaronj0 wants to merge 1 commit into
compiler-research:masterfrom
aaronj0:re-enablepsutil
Open

Re-enable psutil and numba for py3.14#200
aaronj0 wants to merge 1 commit into
compiler-research:masterfrom
aaronj0:re-enablepsutil

Conversation

@aaronj0

@aaronj0 aaronj0 commented Apr 2, 2026

Copy link
Copy Markdown
Collaborator

Since we landed the dispatch mechanism, we support all numba versions from 0.61 - 0.64 and the tests pass (locally). Also re-enable psutil for leakcheck tests.

@aaronj0 aaronj0 requested a review from vgvassilev April 2, 2026 13:33
@aaronj0

aaronj0 commented Apr 2, 2026

Copy link
Copy Markdown
Collaborator Author

valgrind hits something new in latest numpy + openblas:

 vex: priv/host_arm64_defs.c:2832 (genSpill_ARM64): Assertion `offsetB < 4096' failed.
  vex storage: T total 27600686536 bytes allocated
  vex storage: P total 0 bytes allocated
  
  valgrind: the 'impossible' happened:
     LibVEX called failure_exit().
  
  host stacktrace:
  ==10450==    at 0x58044610: show_sched_status_wrk.lto_priv.0 (m_libcassert.c:426)
  ==10450==    by 0x58044657: report_and_quit.lto_priv.0 (m_libcassert.c:497)
  ==10450==    by 0x58048963: panic (m_libcassert.c:572)
  ==10450==    by 0x58048963: vgPlain_core_panic_at (m_libcassert.c:577)
  ==10450==    by 0x58048963: vgPlain_core_panic (m_libcassert.c:582)
  ==10450==    by 0x58056B07: failure_exit (m_translate.c:761)
  ==10450==    by 0x5810EB03: vex_assert_fail (main_util.c:245)
  ==10450==    by 0x58155F4B: genSpill_ARM64 (host_arm64_defs.c:2832)
  ==10450==    by 0x58150637: spill_vreg.lto_priv.0 (host_generic_reg_alloc3.c:339)
  ==10450==    by 0x581088FB: doRegisterAllocation_v3 (host_generic_reg_alloc3.c:1138)
  ==10450==    by 0x581088FB: libvex_BackEnd.lto_priv.0 (main_main.c:1191)
  ==10450==    by 0x5805D577: LibVEX_Translate (main_main.c:1294)
  ==10450==    by 0x5805D577: vgPlain_translate (m_translate.c:1835)
  ==10450==    by 0x5808FAEB: handle_chain_me.lto_priv.0 (scheduler.c:1172)
  ==10450==    by 0x58096B67: vgPlain_scheduler (scheduler.c:1568)
  ==10450==    by 0x580CDDFB: thread_wrapper (syswrap-linux.c:102)
  ==10450==    by 0x580CDDFB: run_a_thread_NORETURN (syswrap-linux.c:154)
  ==10450==    by 0xFFFFFFFFFFFFFFFF: ???
  
  sched status:
    running_tid=1
  
  Thread 1: status = VgTs_Runnable (lwpid 10450)
  ==10450==    at 0x18EEA710: ??? (in /home/runner/work/cppyy/cppyy/CppInterOp/.venv/lib/python3.14/site-packages/numpy.libs/libscipy_openblas64_-7220728c.so)
  client stack range: [0x1FFEFCD000 0x1FFF000FFF] client SP: 0x1FFEFF5AC0
  valgrind stack range: [0x10091C0000 0x10092BFFFF] top usage: 19440 of 1048576
  
  Thread 2: status = VgTs_WaitSys syscall 98 (lwpid 10488)
  ==10450==    at 0x4F91EA0: __futex_abstimed_wait_common64 (futex-internal.c:57)
  ==10450==    by 0x4F91EA0: __futex_abstimed_wait_common (futex-internal.c:87)
  ==10450==    by 0x4F91EA0: __futex_abstimed_wait_cancelable64 (futex-internal.c:139)
  ==10450==    by 0x4F94B1F: __pthread_cond_wait_common (pthread_cond_wait.c:503)
  ==10450==    by 0x4F94B1F: pthread_cond_wait@@GLIBC_2.17 (pthread_cond_wait.c:627)
  ==10450==    by 0x18E9680B: blas_thread_server (in /home/runner/work/cppyy/cppyy/CppInterOp/.venv/lib/python3.14/site-packages/numpy.libs/libscipy_openblas64_-7220728c.so)
  ==10450==    by 0x4F9595B: start_thread (pthread_create.c:447)
  ==10450==    by 0x4FFB8DB: thread_start (clone.S:79)
  client stack range: [0x2240F000 0x22C0DFFF] client SP: 0x22C0D7A0
  valgrind stack range: [0x103081A000 0x1030919FFF] top usage: 4592 of 1048576
  
  Thread 3: status = VgTs_WaitSys syscall 98 (lwpid 10489)
  ==10450==    at 0x4F91EA0: __futex_abstimed_wait_common64 (futex-internal.c:57)
  ==10450==    by 0x4F91EA0: __futex_abstimed_wait_common (futex-internal.c:87)
  ==10450==    by 0x4F91EA0: __futex_abstimed_wait_cancelable64 (futex-internal.c:139)
  ==10450==    by 0x4F94B1F: __pthread_cond_wait_common (pthread_cond_wait.c:503)
  ==10450==    by 0x4F94B1F: pthread_cond_wait@@GLIBC_2.17 (pthread_cond_wait.c:627)
  ==10450==    by 0x18E9680B: blas_thread_server (in /home/runner/work/cppyy/cppyy/CppInterOp/.venv/lib/python3.14/site-packages/numpy.libs/libscipy_openblas64_-7220728c.so)
  ==10450==    by 0x4F9595B: start_thread (pthread_create.c:447)
  ==10450==    by 0x4FFB8DB: thread_start (clone.S:79)
  client stack range: [0x22C1F000 0x2341DFFF] client SP: 0x2341D7A0
  valgrind stack range: [0x103149B000 0x103159AFFF] top usage: 3616 of 1048576
  
  Thread 4: status = VgTs_WaitSys syscall 98 (lwpid 10490)
  ==10450==    at 0x4F91EA0: __futex_abstimed_wait_common64 (futex-internal.c:57)
  ==10450==    by 0x4F91EA0: __futex_abstimed_wait_common (futex-internal.c:87)
  ==10450==    by 0x4F91EA0: __futex_abstimed_wait_cancelable64 (futex-internal.c:139)
  ==10450==    by 0x4F94B1F: __pthread_cond_wait_common (pthread_cond_wait.c:503)
  ==10450==    by 0x4F94B1F: pthread_cond_wait@@GLIBC_2.17 (pthread_cond_wait.c:627)
  ==10450==    by 0x18E9680B: blas_thread_server (in /home/runner/work/cppyy/cppyy/CppInterOp/.venv/lib/python3.14/site-packages/numpy.libs/libscipy_openblas64_-7220728c.so)
  ==10450==    by 0x4F9595B: start_thread (pthread_create.c:447)
  ==10450==    by 0x4FFB8DB: thread_start (clone.S:79)
  client stack range: [0x2342F000 0x23C2DFFF] client SP: 0x23C2D7A0
  valgrind stack range: [0x1031737000 0x1031836FFF] top usage: 4336 of 1048576

To be suppressed..

@mcbarton mcbarton mentioned this pull request Apr 13, 2026
@aaronj0

aaronj0 commented Apr 20, 2026

Copy link
Copy Markdown
Collaborator Author

@Vipul-Cariappa is the following failure a side-effect of compiler-research/CPyCppyy#190?

test_leakcheck.py::TestLEAKCHECK::test02_test_static_methods - TypeError: Template method resolution failed:
    none of the 2 overloaded methods succeeded. Full details:
    static void LeakCheck::MyClass02::static_method_ol(int) =>
      TypeError: could not convert argument 1: [IntConverter] (int conversion expects an integer object)
    static void LeakCheck::MyClass02::static_method_ol(std::string s) =>
      TypeError: could not convert argument 1: [STLStringConverter]
    Failed to instantiate "static_method_ol()"

@vgvassilev vgvassilev left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

Since we landed the dispatch mechanism, we support all numba versions from 0.61 - 0.64 and the tests pass (locally).
Also re-enables psutil for leakcheck tests.
@aaronj0 aaronj0 force-pushed the re-enablepsutil branch from f7d6663 to 7d9e273 Compare May 10, 2026 12:07
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.

2 participants