Using Aspects for Language Portability
Eelco Visser Lennart Kats
Using Aspects for Language Portability Lennart Kats Eelco Visser - - PowerPoint PPT Presentation
Using Aspects for Language Portability Lennart Kats Eelco Visser DSLs Stratego SDF Spoofax DSL compilers (code generators) DSL Generator Backend targets the platform DSL Frontend Backend Backend targets the platform s DSL
Eelco Visser Lennart Kats
DSLs Stratego SDF Spoofax
Generator
Frontend Backend
Frontend Backend
Backend Backend
platform applications
Frontend Backend Backend
Stratego/XT
(spoofax.org)
Primitives Platform libs Backend
Standard libs Programs Frontend Backend Primitives Platform libs Portability aspects
Override functions and library invocations to work with platform-specific libraries
Because we cannot solve all portability problems (right away)
the platform (e.g., POSIX vs. Java)
Warn developers about unportable code Perform “next best” operation
Enhance platform integration:
Address platform performance issues of... ...expensive operations ...common operations (bottlenecks) by using platform-specific code
Many additional portability issues
AOP elegantly addresses them
separate libraries