valgrind-numpy-scipy.supp 3.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140
  1. # Valgrind suppression file for NumPy & SciPy errors and leaks in pybind11 tests
  2. #
  3. # On updating a dependency, to get a list of "default" leaks in e.g. NumPy, run
  4. # `PYTHONMALLOC=malloc valgrind --leak-check=full --show-leak-kinds=definite,indirect python3.9-dbg -c "import numpy"`
  5. # To use theses suppression files, add e.g. `--suppressions=valgrind-numpy-scipy.supp`
  6. {
  7. Leaks when importing NumPy
  8. Memcheck:Leak
  9. fun:malloc
  10. fun:_PyMem_RawMalloc
  11. fun:PyObject_Malloc
  12. fun:_PyObject_GC_Alloc
  13. fun:_PyObject_GC_Malloc
  14. fun:_PyObject_GC_NewVar
  15. fun:tuple_alloc
  16. fun:PyTuple_Pack
  17. ...
  18. fun:__pyx_pymod_exec_*
  19. }
  20. {
  21. Leaks when importing NumPy (bis)
  22. Memcheck:Leak
  23. fun:malloc
  24. fun:_PyMem_RawMalloc
  25. fun:PyObject_Malloc
  26. fun:_PyObject_New
  27. fun:PyCode_NewWithPosOnlyArgs
  28. fun:PyCode_New
  29. ...
  30. fun:__pyx_pymod_exec_*
  31. }
  32. {
  33. Leaks when importing NumPy (ter)
  34. Memcheck:Leak
  35. fun:malloc
  36. fun:_PyMem_RawMalloc
  37. fun:PyObject_Malloc
  38. fun:_PyObject_GC_Alloc
  39. fun:_PyObject_GC_Malloc
  40. fun:_PyObject_GC_NewVar
  41. fun:tuple_alloc
  42. fun:_PyTuple_FromArray
  43. fun:_PyObject_MakeTpCall
  44. fun:_PyObject_VectorcallTstate
  45. fun:PyObject_Vectorcall
  46. fun:call_function
  47. fun:_PyEval_EvalFrameDefault
  48. fun:_PyEval_EvalFrame
  49. fun:function_code_fastcall
  50. fun:_PyFunction_Vectorcall
  51. }
  52. {
  53. Leaks when importing NumPy (quater)
  54. Memcheck:Leak
  55. fun:malloc
  56. fun:_PyMem_RawMalloc
  57. fun:PyObject_Malloc
  58. fun:_PyObject_GC_Alloc
  59. fun:_PyObject_GC_Malloc
  60. fun:_PyObject_GC_NewVar
  61. fun:tuple_alloc
  62. fun:_PyTuple_FromArray
  63. fun:_PyObject_MakeTpCall
  64. fun:_PyObject_VectorcallTstate
  65. fun:_PyObject_CallFunctionVa
  66. fun:PyObject_CallFunction
  67. fun:PyImport_Import
  68. }
  69. {
  70. Leaks when importing NumPy (quinquies)
  71. Memcheck:Leak
  72. fun:malloc
  73. fun:_PyMem_RawMalloc
  74. fun:PyObject_Malloc
  75. fun:_PyObject_GC_Alloc
  76. fun:_PyObject_GC_Malloc
  77. fun:_PyObject_GC_NewVar
  78. fun:tuple_alloc
  79. fun:PyTuple_New
  80. fun:r_object
  81. fun:r_object
  82. fun:r_object
  83. fun:r_object
  84. }
  85. {
  86. Leaks when importing NumPy (sexies)
  87. Memcheck:Leak
  88. fun:malloc
  89. fun:_PyMem_RawMalloc
  90. fun:PyObject_Malloc
  91. fun:_PyObject_GC_Alloc
  92. fun:_PyObject_GC_Malloc
  93. fun:_PyObject_GC_NewVar
  94. fun:tuple_alloc
  95. fun:PyTuple_New
  96. fun:dictiter_iternextitem
  97. fun:list_extend
  98. fun:_PyList_Extend
  99. fun:PySequence_List
  100. }
  101. {
  102. Leak when importing scipy.fft
  103. Memcheck:Leak
  104. fun:_Znwm
  105. fun:PyInit_pypocketfft
  106. fun:_PyImport_LoadDynamicModuleWithSpec
  107. fun:_imp_create_dynamic_impl.constprop.*
  108. fun:_imp_create_dynamic
  109. fun:cfunction_vectorcall_FASTCALL
  110. fun:PyVectorcall_Call
  111. fun:_PyObject_Call
  112. fun:PyObject_Call
  113. fun:do_call_core
  114. fun:_PyEval_EvalFrameDefault
  115. fun:_PyEval_EvalFrame
  116. fun:_PyEval_EvalCode
  117. }
  118. {
  119. NumPy leaks when spawning a subprocess
  120. Memcheck:Leak
  121. fun:malloc
  122. ...
  123. fun:_buffer_get_info
  124. fun:array_getbuffer
  125. fun:PyObject_GetBuffer
  126. fun:__Pyx__GetBufferAndValidate*
  127. fun:__pyx_f_5numpy_6random_13bit_generator_12SeedSequence_mix_entropy
  128. fun:__pyx_pw_5numpy_6random_13bit_generator_12SeedSequence_1__init__
  129. fun:type_call
  130. fun:__Pyx__PyObject_CallOneArg
  131. fun:__pyx_pw_5numpy_6random_13bit_generator_12BitGenerator_1__init__
  132. }