We examine the issues involved in producing a backend for the GNU Compiler Collection (GCC) that targets the .NET Common Language Runtime. We describe a simple back-end that is written in standard GCC style, which interfaces with the register transfer language GCC intermediate representation. We demonstrate that this simple .NET back-end is able to compile an appreciable subset of the C language. We then consider support for function call handling, object-orientation and language interoperability, amongst other things. Problems arise because GCC discards much information which could be used to enhance the .NET code generation phase. We briefly describe several possible alternative methods of creating a GCC .NET backend, which might produce more effective .NET bytecode.
[1]
Fred P. Brooks,et al.
The Mythical Man-Month
,
1975,
Reliable Software.
[2]
David R. Hanson.
lcc.NET: targeting the .NET Common Intermediate Language from Standard C
,
2004,
Softw. Pract. Exp..
[3]
Frank Yellin,et al.
The Java Virtual Machine Specification
,
1996
.
[4]
Serge Lidin,et al.
Inside Microsoft .Net Il Assembler
,
2002
.
[5]
Nathaniel Nystrom,et al.
BLOAT: Bytecode-level optimizer and analysis tool
,
1999
.
[6]
P. Kidwell,et al.
The mythical man-month: Essays on software engineering
,
1996,
IEEE Annals of the History of Computing.
[7]
John John Gough,et al.
Compiling for the .NET Common Language Runtime
,
2001
.