Graduate Talks
PhD Presentation
Cosmin Oancea
Parametric Polymorphism for Software Component Architectures
Time:
Place:
Supervisor:
Thesis Examiners:
Extra-Departmental
Examiner:
External Examiner:
9:30 a.m.
Middlesex College, Room 320
Dr. Stephen Watt
Dr. Hanan Lutfiyya
Dr. Marc Moreno Maza
Martin Mueser (Applied Mathematics)
Nigel Horspool (Univ. of Victoria)
Abstract:
Parametric polymorphism has become a common feature of mainstream
programming languages, but software component architectures have lagged
behind and do not support this feature. The immediate consequence is that
applications cannot naturally combine the functionality exposed by various
parameterized modules, if it happens that the implementation language
differs. This significant problem surfaced first and most acutely in the
computer algebra community, where parametric polymorphism is heavily used
for the specification and enforcement of the algebraic interfaces and in
the implementation of algorithms that work over various coefficient rings
or fields. Complex, specialized mathematical libraries, servicing disjoint
areas are implemented in various languages and therefore they cannot yet
work together to attack increasingly difficult problems. This thesis
examines the problem of accommodating parametric polymorphism, and related
optimizations in a multi-language, distributed setting.
We report on a first experiment, where we developed the Alma framework that
allows Aldor libraries to extend Maple in a effective and natural way, and
constitutes a new approach to structuring computer algebra systems. The
motivation for this experiment are twofold: First, we are interested in
understanding the issues that arise in matching the compile-time parametric
polymorphism of Aldor's dependent types with the dynamic parametric
polymorphism of Maple's module-producing functions, and in matching the
Aldor's strongly type system with Maple's dynamically typed
system. Second, we are interested in the practical problem of using Aldor
as an extension mechanism for the popular Maple computer algebra system.
The details of generics, templates or functors, as they are variously
called, differ significantly in different programming languages. We
investigated how to resolve different binding times and parametric
polymorphism semantics in a range of representative programming languages,
and identified a common ground that can be suitably mapped to different
language bindings. We explore the possibility of a systematic solution for
parametric polymorphism, that should encompass many languages in a simple
way. We present a generic component architecture extension that provides
support for parameterized components, and can be easily adapted to work on
top of various software component architectures in use today: CORBA, JNI,
DCOM. We have implemented and tested our extension on top of CORBA. We
present Generic Interface Definition Language (GIDL), an extension to
CORBA-IDL, supporting generic types, and our language bindings for C++,
Java, and Aldor. We describe our implementation of GIDL, consisting of a
GIDL to IDL compiler and tools for generating linkage code under the
language bindings. GIDL captures a very general notion of parametric
polymorphism such that it can meaningfully be supported by various
languages, and has the power to model the structure and semantics of
system's components. To test the effectiveness of our model for generics,
we have investigated how to expose C++'s STL and Aldor's BasicMath
libraries to a multi-language environment, and discuss our mappings in the
context of automatic library interface generation. Our work in the context
of exposing generic libraries to a multi-language, potentially distributed
environment has revealed several performance issues. First, as different
components are separately compiled, the traditional compiler optimizations,
such as inlining and parallelization, will fail to perform
aggressively. Second, the overhead introduced by the inter-process
communication stalls can be quite significant. Finally, this thesis
explores speculative optimizations in the attempt to speed up the
application performance in distributed environments.
Also from this web page:

