STINNER Victor <vstin...@python.org> added the comment:

Count static types:

grep -E 'static PyTypeObject .* =' $(find -name "*.c"|grep -v Doc/)|wc -l

Count heap types:

grep -E 'PyType_Spec .* =' $(find -name "*.c")|wc -l

Status:

* 3.6: 10 heap (6%) vs 145 static (total: 155)
* 3.7: 10 heap (6%) vs 150 static (total: 160)
* 3.8: 15 heap (9%) vs 157 static (total: 172)
* 3.9: 39 heap (21%) vs 149 static (total: 188) -- 2.6x more heap types than 
3.8!
* master: 69 heap (35%) vs 131 static (total: 200) -- 1.8x more heap types than 
3.9!

The percentage of heap static is growing in the right direction ;-) The total 
number of types is also growing at each Python realease!

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue40077>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to