Re: !generating ILAsm / compiler question

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



First, a few definitions. They are not necessarily important to the question, but they are important to understand the process. The "language" is IL, for Intermediate Language or MSIL for Microsoft Intermediate Language. It is considered compiled, as it can be picked up by the CLR and run without any further "outside" intervention. If it still required more intervention from a user, it would only be translated.

The main reason someone builds a compiler rather than a translator is to build running code. Technically, you could build a translator and then fire off a compiler, but you then have to trust the other compiler. If you write in C#, C++ or VB, you will find the compilers are each better at something different. They are functionally equivalent, but not exactly equal in their IL output.

As a software developer, you would prefer something where you have left your destiny under your own control, rather than partially under your control and partially under the control of another piece of software. This is if your goal is compilation. You also prefer the least number of moving parts, as more moving parts means more potential points of failure.

There is certainly value in translating one high level language to another. It is completely different from compiling.

--
Gregory A. Beamer
MVP, MCP: +I, SE, SD, DBA

Subscribe to my blog
http://feeds.feedburner.com/GregoryBeamer#

or just read it:
http://feeds.feedburner.com/GregoryBeamer

********************************************
| Think outside the box! |
********************************************
"ajk" <anders43@xxxxxxxxx> wrote in message news:6528baed-11b6-40ad-811a-1bd816033f10@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Hi

When doing a .NET compiler what are the benefits of generating ILAsm
directly compared to generating another higher level language like C#
first and then using the C# compiler?

Round-tripping will not work and debugging may be easier, any other
reasons why it would be prefered to generate ILAsm?

tia/ajk

.



Relevant Pages

  • Re: "STL from the Ground Up"
    ... high-level intermediate language than can interoperate with many other ... If your language lacks expressive features then you cannot write code ... memory management in comparison. ... Mostly because type errors mean that the programmer and compiler disagree ...
    (comp.programming)
  • Coding a translator between languages with high abstraction levels
    ... Language embedded in Haskell, http://www.haskell.org/). ... I don't have much experience in compiler design and development apart ... translator as a Haskell compiler backend (ForSyDe is just Haskell ...
    (comp.compilers)
  • Re: A note on computing thugs and coding bums
    ... It would handle international characters if the execution character ... method I used in "Build Your Own .Net Language and Compiler". ... work areas and counting on Nul is an illusion. ...
    (comp.programming)
  • Re: access(FULLPATH, xxx);
    ... with "trial& error" to just silence the compiler. ... void *foo); ... given that the language in the specification _was_ abiguous and both ... documentation was paramount. ...
    (freebsd-questions)
  • Writing a Roguelike in D, C# and C++
    ... Since I have seen some interest on this newsgroup about which language ... The official compiler is dmd. ... The roguelike I am writing uses variable sized glyphs. ... trigger Hejlberg's garbage collector. ...
    (rec.games.roguelike.development)