Skip to content

Commit 721834b

Browse files
chore: get PyPy 3.7 wheels using NumPy 1.20 (#2837)
* chore: get PyPy 3.7 wheels using NumPy 1.20 * Add Valgrind suppressions after NumPy update Co-authored-by: Yannick Jadoul <[email protected]>
1 parent 6cf6bf2 commit 721834b

File tree

3 files changed

+26
-21
lines changed

3 files changed

+26
-21
lines changed

tests/requirements.txt

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
--extra-index-url https://antocuni.github.io/pypy-wheels/manylinux2010/
22
numpy==1.16.6; python_version<"3.6" and sys_platform!="win32"
33
numpy==1.18.0; platform_python_implementation=="PyPy" and sys_platform=="darwin" and python_version>="3.6"
4-
numpy==1.19.3; (platform_python_implementation!="PyPy" or sys_platform=="linux") and python_version>="3.6" and python_version<"3.10"
4+
numpy==1.19.3; (platform_python_implementation!="PyPy" or sys_platform=="linux") and python_version=="3.6"
5+
numpy==1.20.0; (platform_python_implementation!="PyPy" or sys_platform=="linux") and python_version>="3.7" and python_version<"3.10"
56
pytest==4.6.9; python_version<"3.5"
67
pytest==6.1.2; python_version=="3.5"
78
pytest==6.2.1; python_version>="3.6"

tests/valgrind-numpy-scipy.supp

+24-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,8 @@
11
# 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`
26

37
{
48
Leaks when importing NumPy
@@ -29,7 +33,7 @@
2933
}
3034

3135
{
32-
Leaks when importing NumPy (tris)
36+
Leaks when importing NumPy (ter)
3337
Memcheck:Leak
3438
fun:malloc
3539
fun:_PyMem_RawMalloc
@@ -59,6 +63,24 @@
5963
fun:_PyObject_GC_Malloc
6064
fun:_PyObject_GC_NewVar
6165
fun:tuple_alloc
66+
fun:_PyTuple_FromArray
67+
fun:_PyObject_MakeTpCall
68+
fun:_PyObject_VectorcallTstate
69+
fun:_PyObject_CallFunctionVa
70+
fun:PyObject_CallFunction
71+
fun:PyImport_Import
72+
}
73+
74+
{
75+
Leaks when importing NumPy (quinquies)
76+
Memcheck:Leak
77+
fun:malloc
78+
fun:_PyMem_RawMalloc
79+
fun:PyObject_Malloc
80+
fun:_PyObject_GC_Alloc
81+
fun:_PyObject_GC_Malloc
82+
fun:_PyObject_GC_NewVar
83+
fun:tuple_alloc
6284
fun:PyTuple_New
6385
fun:r_object
6486
fun:r_object
@@ -67,7 +89,7 @@
6789
}
6890

6991
{
70-
Leaks when importing NumPy (quinquies)
92+
Leaks when importing NumPy (sexies)
7193
Memcheck:Leak
7294
fun:malloc
7395
fun:_PyMem_RawMalloc

tests/valgrind-python.supp

-18
Original file line numberDiff line numberDiff line change
@@ -115,21 +115,3 @@
115115
fun:_PyImport_FindSharedFuncptr
116116
fun:_PyImport_LoadDynamicModuleWithSpec
117117
}
118-
119-
# Not really CPython-specific, see link
120-
{
121-
dlopen leak (https://stackoverflow.com/questions/1542457/memory-leak-reported-by-valgrind-in-dlopen)
122-
Memcheck:Leak
123-
fun:malloc
124-
...
125-
fun:dl_open_worker
126-
fun:_dl_catch_exception
127-
fun:_dl_open
128-
fun:dlopen_doit
129-
fun:_dl_catch_exception
130-
fun:_dl_catch_error
131-
fun:_dlerror_run
132-
fun:dlopen@@GLIBC_2.2.5
133-
fun:_PyImport_FindSharedFuncptr
134-
fun:_PyImport_LoadDynamicModuleWithSpec
135-
}

0 commit comments

Comments
 (0)