A recent technical note from Microsoft describes a new reference counting 
algorithm, Perceus. It seemed worth posting here in case there are any thoughts 
about whether it might be useful for Python. I couldn't find any existing 
references to it in this list.

"""
We introduce Perceus, an algorithm for precise reference counting with reuse 
and specialization. Starting from a func- tional core language with explicit 
control-flow, Perceus emits precise reference counting instructions such that 
programs are garbage free, where only live references are retained. This 
enables further optimizations, like reuse analysis that allows for guaranteed 
in-place updates at runtime. This in turn enables a novel programming paradigm 
that we call functional but in-place (FBIP). Much like tail-call optimiza- tion 
enables writing loops with regular function calls, reuse analysis enables 
writing in-place mutating algorithms in a purely functional way. We give a 
novel formalization of ref- erence counting in a linear resource calculus, and 
prove that Perceus is sound and garbage free. We show evidence that Perceus, as 
implemented in Koka, has good performance and is competitive with other 
state-of-the-art memory collectors.
"""

https://www.microsoft.com/en-us/research/uploads/prod/2020/11/perceus-tr-v1.pdf
_______________________________________________
Python-Dev mailing list -- python-dev@python.org
To unsubscribe send an email to python-dev-le...@python.org
https://mail.python.org/mailman3/lists/python-dev.python.org/
Message archived at 
https://mail.python.org/archives/list/python-dev@python.org/message/7KJAGPJZ66U4GGGABWMVDEPW6RDJ2XT7/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to