Reference counting for reversible languages

Research output: Chapter in Book/Report/Conference proceedingArticle in proceedingsResearchpeer-review

Modern programming languages and operating systems use heap memory
that allows allocation and deallocation of memory to be decoupled, so
they don't follow a stack discipline. Axelsen and Glück have
presented a reversible heap manager where allocation and deallocation
are each other's logical inverses: Freeing a block of memory is done
by running the allocation procedure backwards.

Axelsen and Glück use this heap manager to sketch implementation of a
simple reversible functional language where pattern matching a
constructor is the inverse of construction, so pattern-matching
implies deallocation. This requires the language to be linear: A
pointer can not be copied and it can only be eliminated by
deallocating the node to which it points.

We overcome this limitation by adding reference counts to nodes:
Copying a pointer to a node increases the reference count of the node
and eliminating a pointer decreases the reference count. We show
reversible implementations of operations on nodes with reference
counts. We then show these operations can be used when implementing a
reversible functional language RCFUN to the reversible imperative
language Janus.
Original languageEnglish
Title of host publicationReversible Computation : 6th International Conference, RC 2014, Kyoto, Japan, July 10-11, 2014. Proceedings
EditorsShigeru Yamashita, Shin-ichi Minato
Number of pages13
PublisherSpringer
Publication date2014
Pages82-94
ISBN (Print)978-3-319-08493-0
ISBN (Electronic)978-3-319-08494-7
DOIs
Publication statusPublished - 2014
Event6th International Conference on Reversible Computation - Kyoto, Japan
Duration: 10 Jul 201411 Jul 2014
Conference number: 6

Conference

Conference6th International Conference on Reversible Computation
Nummer6
LandJapan
ByKyoto
Periode10/07/201411/07/2014
SeriesLecture notes in computer science
Volume8507
ISSN0302-9743

ID: 149085667