Flexible Bytecode for Linking in .NET

Dynamic linking in modern execution environments like .NET is considerably more sophisticated than in the days of C shared libraries on UNIX. One aspect of this sophistication is that .NET assemblies embed type information about dynamically linked resources. This type information implicitly represents compile-time assumptions about the resources available at run-time. However, the resources available at run-time may differ from those available at compile-time. For example, the execution environment on a mobile phone might provide fewer, simpler classes than on a desktop PC. As bytecode cannot adapt to its execution environment, component reuse is restricted and development costs are increased. We have designed and implemented a ''flexible'' dynamic linking scheme that binds bytecode as late as possible to the assemblies and classes available in a .NET execution environment. We describe the scheme's integration with the .NET linking infrastructure, review important design decisions and report on experiences with the ''Rotor'' shared source version of .NET.

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

[2]  Michael Franz Dynamic Linking of Software Components , 1997, Computer.

[3]  William G. Griswold,et al.  An Overview of AspectJ , 2001, ECOOP.

[4]  Susan Eisenbach,et al.  Feeling the way through DLL hell , 2002 .

[5]  Shigeru Chiba,et al.  Load-Time Structural Reflection in Java , 2000, ECOOP.

[6]  Antonio Cisternino,et al.  CodeBricks: code fragments as building blocks , 2003, PPoPP 2003.

[7]  Martin Odersky,et al.  Making the future safe for the past: adding genericity to the Java programming language , 1998, OOPSLA '98.

[8]  Frank Tip,et al.  Refactoring for generalization using type constraints , 2003, OOPSLA 2003.

[9]  Éric Tanter,et al.  Altering Java Semantics via Bytecode Manipulation , 2002, GPCE.

[10]  Andrew Kennedy,et al.  Design and implementation of generics for the .NET Common language runtime , 2001, PLDI '01.

[11]  Drew Dean,et al.  The security of static typing with dynamic linking , 1997, CCS '97.

[12]  Davide Ancona,et al.  Polymorphic bytecode: compositional compilation for Java-like languages , 2005, POPL '05.

[13]  John Gough,et al.  Technical Overview of the Common Language Runtime , 2001 .

[14]  Iain D. Craig,et al.  The Java Virtual Machine , 2006 .

[15]  Antonio Cisternino,et al.  CIL + Metadata > Executable Program , 2004, J. Object Technol..

[16]  Sophia Drossopoulou An Abstract Model of Java Dynamic Linking and Loading , 2000, Types in Compilation.

[17]  Sophia Drossopoulou,et al.  Flexible Models for Dynamic Linking , 2003, ESOP.

[18]  Robert C. Seacord Replaceable Components and the Service Provider Interface , 2002, ICCBSS.

[19]  Wouter Joosen,et al.  Support for Metadata-driven Selection of Run-time Services in .NET is Promising but Immature , 2004, J. Object Technol..

[20]  Daniel Le Métayer,et al.  Security and dynamic class loading in Java: a formalisation , 1998, Proceedings of the 1998 International Conference on Computer Languages (Cat. No.98CB36225).