Towards Hybrid Intensional Programming with JLucid, Objective Lucid, and General Imperative Compiler Framework in the GIPSY

Serguei A. Mokhov
DOI: https://doi.org/10.48550/arXiv.0907.2640
2009-12-21
Abstract:Pure Lucid programs are concurrent with very fine granularity. Sequential Threads (STs) are functions introduced to enlarge the grain size; they are passed from server to workers by Communication Procedures (CPs) in the General Intensional Programming System (GIPSY). A JLucid program combines Java code for the STs with Lucid code for parallel control. Thus first, in this thesis, we describe the way in which the new JLucid compiler generates STs and CPs. JLucid also introduces array support. Further exploration goes through the additional transformations that the Lucid family of languages has undergone to enable the use of Java objects and their members, in the Generic Intensional Programming Language (GIPL), and Indexical Lucid: first, in the form of JLucid allowing the use of pseudo-objects, and then through the specifically-designed the Objective Lucid language. The syntax and semantic definitions of Objective Lucid and the meaning of Java objects within an intensional program are provided with discussions and examples. Finally, there are many useful scientific and utility routines written in many imperative programming languages other than Java, for example in C, C++, Fortran, Perl, etc. Therefore, it is wise to provide a framework to facilitate inclusion of these languages into the GIPSY and their use by Lucid programs. A General Imperative Compiler Framework and its concrete implementation is proposed to address this issue.
Programming Languages,Software Engineering
What problem does this paper attempt to address?
The problems that this paper attempts to solve mainly focus on the following aspects: 1. **Limitations in Distributed Computing**: There were some limitations in the previous General Intensional Programming System (GIPSY) prototype, such as the lack of Sequential Threads (STs) and Communication Procedures (CPs), which limited its potential in distributed computing. 2. **Extension of Language Features**: Indexical Lucid and Generic Intensional Programming Language (GIPL), as the main languages of GIPSY, have limited computational capabilities. They lack input/output, arrays, and some other basic features (such as mathematical operations, non - determinism, dynamic loading, etc.) that exist in imperative languages like Java. 3. **Embedding of Java Methods**: By introducing JLucid, the paper has solved the problem of how to embed Java methods into Intensional programming languages, enabling these languages to handle Java methods as first - class values. This not only enhances the functionality of Intensional languages but also makes it possible to utilize existing Java libraries. 4. **Lack of Object Support**: Although JLucid allows the embedding of Java methods, it does not support Java objects and their member operations. For this reason, the paper has designed Objective Lucid to fill this gap and defined the operational semantics of Objective Lucid, providing application examples. 5. **Requirement for Multilingual Integration**: Since there are many useful libraries written in other imperative languages (such as C/C++, Perl, Python, Fortran, etc.), a framework is required to enable Intensional programs to use the code written in these languages. For this purpose, the paper has designed a preliminary version of the General Imperative Compiler Framework (GICF) as part of GIPSY, allowing GIPSY programs to use almost any combination of Intensional and imperative languages at the meta - level. In summary, the main objective of the paper is to enhance the functionality of GIPSY by introducing JLucid and Objective Lucid and designing GICF, making it more flexible and powerful and better able to support distributed computing and multilingual integration.