Using Oberon's active objects for language interoperability and compilation

The modern run-time environments provide a high-level object-oriented programming model, reflection capabilities, and a large amount of libraries. These platforms are particularly suitable to host programs written in many different languages. To let all languages reuse the common libraries, the platform has a reflection mechanisms to access the metadata information, which can be used by the compilers to provide language interoperability in a seamless way. Writing a compiler for such platforms becomes an exercise in programming model mapping. Most of the languages rely on closely related flavors of the object-oriented model, but the mappings from one model to another are not always trivial. This thesis investigates the implementation of a language interoperability platform based on an active object-based object-oriented model. First, it analyzes the relations between the type systems of the platform and its subset used for interoperability, and the languages for the platform. Each language type system must be mappable to the platform type system, and the interoperability type system must be bidirectionally mappable to every language type system. Many languages implement a different flavor of the object-oriented model. A few simple mapping rules to transform each flavor onto another one are presented. Second, the Aos kernel implementing Active Oberon’s active object model is introduced as language interoperability platform. The language Active Oberon is presented as natural notation for the active object model. The Paco scope-parallel Active Oberon compiler is a case study that shows a non-trivial application relying on active objects. It parses each scope concurrently and solves forward references in the code with parser synchronization, instead of requiring a second parsing pass. Third, the Jaos Java Virtual Machine for Aos is presented. The jit-compiler maps the Java model to the active object model, and compiles the java byte-code using the data-layout and facilities provided by the kernel; the jit-compiler and the Java reflection libraries use the same metadata repository as the Active Oberon compiler: this allows both languages to interoperate seamlessly. Plugins for the metadata repository and for the kernel’s dynamic loader allow to use multiple metadata persistency formats and multiple object-file formats at the same time.

[1]  Andreas R. Disteli,et al.  Combining Oberon with Active Objects , 1997, JMLC.

[2]  David B. Wortman,et al.  An investigation into concurrent semantic analysis , 1991, Softw. Pract. Exp..

[3]  Murray Hill,et al.  Yacc: Yet Another Compiler-Compiler , 1978 .

[4]  Jean-Marc Jézéquel,et al.  Making Components Contract Aware , 1999, Computer.

[5]  K. Beck,et al.  Extreme Programming Explained , 2002 .

[6]  Pieter Johannes Muller,et al.  The active object system design and multiprocessor implementation , 2002 .

[7]  Robert Griesemer,et al.  A programming language for vector computers , 1993 .

[8]  Niklaus Wirth,et al.  The programming language oberon , 1988, Softw. Pract. Exp..

[9]  Jürg Gutknecht Active Oberon for .NET: An Exercise in Object Model Mapping , 2001, Electron. Notes Theor. Comput. Sci..

[10]  K. John Gough,et al.  Evaluating the Java Virtual Machine as a Target for Languages Other Than Java , 2000, JMLC.

[11]  Eric S. Raymond,et al.  Cathedral & the Bazaar: Musings on Linux and Open Source by an Accidental Revolutionary , 2001 .

[12]  P. Kidwell,et al.  The mythical man-month: Essays on software engineering , 1996, IEEE Annals of the History of Computing.

[13]  Peter H. Frohlich Projekt froderon: Zur weiteren entwicklung der programmiersprache oberon-2 , 1997 .

[14]  Andrew W. Appel,et al.  Smartest recompilation , 1993, POPL '93.

[15]  Beat Heeb,et al.  Chameleon: A Workstation of a Different Colour , 1992, FPL.

[16]  David A. Patterson,et al.  Computer Architecture: A Quantitative Approach , 1969 .

[17]  Jeffery von Ronne,et al.  SafeTSA: a type safe and referentially secure mobile-code representation based on static single assignment form , 2001, PLDI '01.

[18]  Richard Stanley Ohran Lilith: a workstation computer for Modula-2 , 1984 .

[19]  Bertrand Meyer Overloading vs. object technology , 2001 .

[20]  C. A. R. Hoare,et al.  Communicating sequential processes , 1978, CACM.

[21]  Edsger W. Dijkstra,et al.  The structure of the “THE”-multiprogramming system , 1968, CACM.

[22]  簡聰富,et al.  物件導向軟體之架構(Object-Oriented Software Construction)探討 , 1989 .

[23]  Egon Börger,et al.  Java and the Java Virtual Machine: Definition, Verification, Validation , 2001 .

[24]  Clemens A. Szyperski,et al.  Import is Not Inheritance - Why We Need Both: Modules and Classes , 1992, ECOOP.

[25]  Régis Bernard Joseph Crelier,et al.  Separate compilation and module extension , 1994 .

[26]  Spyros Lalis,et al.  Adding Concurrency to the Oberon System , 1994, Programming Languages and System Architectures.

[27]  Sheng Liang,et al.  Java Native Interface: Programmer's Guide and Specification , 1999 .

[28]  Bowen Alpern,et al.  Efficient implementation of Java interfaces: Invokeinterface considered harmless , 2001, OOPSLA '01.

[29]  Anas N. Al-Rabadi,et al.  A comparison of modified reconstructability analysis and Ashenhurst‐Curtis decomposition of Boolean functions , 2004 .

[30]  Svend Erik Knudsen Medos-2: a Modula-2 oriented operating system for the personal computer Lilith , 1983 .

[31]  Luca Cardelli,et al.  On understanding types, data abstraction, and polymorphism , 1985, CSUR.

[32]  Robert Griesemer,et al.  A Compiler for the Java HotSpotTM Virtual Machine , 2000, The School of Niklaus Wirth.

[33]  Per Brinch Hansen,et al.  Structured multiprogramming , 1972, CACM.

[34]  Guy L. Steele,et al.  The Java Language Specification , 1996 .

[35]  Vitaly V. Mikheev Design of Multilingual Retargetable Compilers: Experience of the XDS Framework Evolution , 2000, JMLC.

[36]  Richard L. Wexelblat History of programming languages I , 1978 .

[37]  Alfonso Pierantonio,et al.  The Formal Specification of Oberon , 1997, J. Univers. Comput. Sci..

[38]  Niklaus Wirth,et al.  Modula: A language for modular multiprogramming , 1977, Softw. Pract. Exp..

[39]  Hanspeter Moessenboeck,et al.  Coco/R - A Generator for Fast Compiler Front Ends , 1990 .

[40]  Niklaus Wirth,et al.  Modula: A language for modular multiprogramming , 1977, Softw. Pract. Exp..

[41]  Patrik Reali,et al.  Structuring a Compiler with Active Objects , 2000, JMLC.

[42]  Patrick Chan,et al.  The Java™ Class Libraries, Volume 2: java.applet, java.awt, java.beans , 1997 .

[43]  Niklaus Wirth,et al.  Programming in Oberon - steps beyond Pascal and Modula , 1992 .

[44]  Dale Rogerson,et al.  Inside COM , 1997 .

[45]  Murray Hill,et al.  Why Pascal is Not My Favorite Programming Language , 1981 .

[46]  Hanspeter Mössenböck,et al.  Object Oberon: An object-oriented extension of Oberon , 1989 .

[47]  Eric Lease Morgan,et al.  Review of The Cathedral & the Bazaar: Musings on Linux and Open Source by an Accidental Revolutionary by Eric S. Raymond, Sebastopol, Calif.: O'Reilly, 1999 , 2000 .

[48]  Thomas J. Bergin,et al.  History of programming languages---II , 1996 .

[49]  Hanspeter Mössenböck,et al.  The Programming Language Oberon-2 , 1991, Struct. Program..

[50]  Atanas Radenski Introducing Objects and Parallelism to an Imperative Programming Language , 1995, Inf. Sci..

[51]  David B. Wortman,et al.  A concurrent compiler for Modula-2+ , 1992, PLDI '92.

[52]  Frank Yellin,et al.  The Java Virtual Machine Specification , 1996 .

[53]  C. A. R. Hoare,et al.  Monitors: an operating system structuring concept , 1974, CACM.

[54]  Clemens A. Szyperski,et al.  Component software - beyond object-oriented programming , 2002 .

[55]  Peter Januschke Oberon-XSC: eine Programmiersprache und Arithmetikbibliothek für das Wissenschaftliche Rechnen , 1998 .

[56]  Johannes Leon Marais Design and implementation of a component architecture for Oberon , 1996 .

[57]  C. M. Sperberg-McQueen,et al.  eXtensible Markup Language (XML) 1.0 (Second Edition) , 2000 .

[58]  Eric S. Raymond,et al.  The cathedral and the bazaar - musings on Linux and Open Source by an accidental revolutionary , 2001 .

[59]  Hanspeter Mössenböck Compiler Construction - The Art of Niklaus Wirth , 2000, The School of Niklaus Wirth.

[60]  Rosanna Lee,et al.  The Java Class Libraries, Volume 1: java.io, java.lang, java.math, java.net, java.text, java.util , 1998 .

[61]  Andreas R. Disteli Integration aktiver Objekte in Oberon am Beispiel eines Serversystems , 1997 .

[62]  Niklaus Wirth,et al.  Project Oberon - the design of an operating system and compiler , 1992 .

[63]  Maurice H. Halstead,et al.  Elements of software science , 1977 .

[64]  Pieter Muller A Multiprocessor Kernel for Active Object-Based Systems , 2000, JMLC.

[65]  Andrew S. Tanenbaum,et al.  Structured Computer Organization , 1976 .

[66]  Michael Steffen Oliver Franz,et al.  Code_generation On_the_fly: a Key to Portable Software , 1994 .

[67]  Johann Jakob Eberle Development and analysis of a workstation computer , 1987 .

[68]  David Seal,et al.  ARM Architecture Reference Manual , 2001 .

[69]  James M. Stichnoth,et al.  Practicing JUDO: Java under dynamic optimizations , 2000, PLDI '00.

[70]  Harold Thimbleby A critique of Java , 1999 .

[71]  Niklaus Wirth,et al.  Grundlagen und Techniken des Compilerbaus , 1996 .

[72]  Atanas Radenski Module embedding e]radenski@ga.unc.edu , 1998, Softw. Concepts Tools.

[73]  C. M. Sperberg-McQueen,et al.  Extensible Markup Language (XML) , 1997, World Wide Web J..

[74]  Gregory R. Andrews,et al.  Concurrent programming - principles and practice , 1991 .

[75]  Fred P. Brooks,et al.  The Mythical Man-Month , 1975, Reliable Software.

[76]  Ali-Reza Adl-Tabatabai,et al.  Fast, effective code generation in a just-in-time Java compiler , 1998, PLDI.

[77]  Hanspeter Mössenböck Objektorientierte Programmierung in Oberon-2 , 1994 .

[78]  Stephen J. Fink,et al.  The Jalapeño virtual machine , 2000, IBM Syst. J..