1 / 9

Translation, simulation and other exercises with reversible languages

Translation, simulation and other exercises with reversible languages. Holger Bock Axelsen Dept. of Computer Science, DIKU University of Copenhagen. GRACE Int’l Meeting on Bidirectional Transformations. What can reversible languages compute ?.

vega
Télécharger la présentation

Translation, simulation and other exercises with reversible languages

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Translation, simulation and other exercises with reversible languages Holger Bock Axelsen Dept. of Computer Science, DIKU University of Copenhagen GRACE Int’l Meeting on Bidirectional Transformations

  2. Whatcan reversible languagescompute? • Restriction: Logicalreversibilityimpliesthatwecanonlycomputeinjectivefunctionsin reversible languages. Programs Functions Computable functions Turing Machines Rev. TM Injective computable functions Injective functions

  3. Reversible computing vs.bidirectional transformations • Computing injective functions: Anatural choice for bidirectional transformation? • That’s what I’m here to find out…

  4. Translation • Janus -> PISAcompiler T. PISA: Reversible assembler • Atomic stmt: x+=e (x := x+e) • T(+=)is easy: ADD$a $b ($a <- $a + $b) • T(e)istricky: • Problem:expression evaluation is irreversible, even thoughstatementevaluation is reversible!) • PISA cannotcompute [[e]]!

  5. …Orcan it? • Question: Can all computationsbe done reversibly? • Answer: Yes, byextendingthe output withgarbage, ensuringreversibility. • Landauer (1961): Add a trace. • Bennett (1973): Copy the input to the output. • Problem: Altering the type of the computedfunction.

  6. Translation strategy • Evaluatinge is irreversible. • But wecanevaluateexpressionsreversiblyusinggarbage. • Uncomputation is easy: Inversion of PISA code fore. • Use a version of the local Bennett trick (reversible update). 1. Computee + garbage. 2. Updatex with the result of e. 3.Uncomputee + garbage. x+=e Semantics-preservingtranslation T(x += e)

  7. Church-Turingthesis: Reversible Computing Version • ClassicalChurch-Turingthesis: If functionf is computable in languageS, then it is computable in anyotherlanguageT. • Reversible Church-Turingthesis (RCT): If functionf is computable in reversiblelanguageS, then it is computable in anyother reversible languageT. Specifically, withoutaltering the type of the computedfunction.

  8. r-Turingcompleteness • The RCT saysthat reversible languagescancomputeexactly the same functions. The type is conserved (modulo data representation). • Suggeststhat reversible languagescansimulateeachothercleanly. • Clean: Nogarbagenecessary. No Landauer embedding, Bennett trick, oranyother ”injectivization” is inherentlynecessarywhendealingwith simulation of reversible languages! • Definition: A reversible language is r-Turingcompleteiff it cansimulate reversible Turingmachinescleanly.

  9. Possible talks • Reversible flowchart languages (~25min.): • Proof that structured programs are as computationally strong as unstructured, in RC. • r-Turing completeness demonstrated. • Injectivization of classical Turing machines. • Janus -> PISA compilation (~45min.): • More on reversibility. • CFO, procedure call translation. • Register allocation.

More Related