Path: csiph.com!x330-a1.tempe.blueboxinc.net!newsfeed.hal-mli.net!feeder3.hal-mli.net!nx01.iad01.newshosting.com!newshosting.com!69.16.185.16.MISMATCH!npeer02.iad.highwinds-media.com!news.highwinds-media.com!feed-me.highwinds-media.com!border3.nntp.dca.giganews.com!border1.nntp.dca.giganews.com!nntp.giganews.com!news.iecc.com!nerds-end From: BGB Newsgroups: comp.compilers Subject: Re: Need an interesting topic for an undergraduate project on Compilers Date: Wed, 31 Aug 2011 10:41:43 -0700 Organization: albasani.net Lines: 22 Sender: news@iecc.com Approved: comp.compilers@iecc.com Message-ID: <11-08-030@comp.compilers> References: <11-08-006@comp.compilers> <11-08-007@comp.compilers> <11-08-029@comp.compilers> NNTP-Posting-Host: news.iecc.com X-Trace: gal.iecc.com 1314797528 44752 64.57.183.58 (31 Aug 2011 13:32:08 GMT) X-Complaints-To: abuse@iecc.com NNTP-Posting-Date: Wed, 31 Aug 2011 13:32:08 +0000 (UTC) Keywords: courses, assembler Posted-Date: 31 Aug 2011 09:32:08 EDT X-submission-address: compilers@iecc.com X-moderator-address: compilers-request@iecc.com X-FAQ-and-archives: http://compilers.iecc.com Xref: x330-a1.tempe.blueboxinc.net comp.compilers:247 On 8/27/2011 8:30 AM, Joe keane wrote: > Volker Birk writes: >> If you want to compile a programming language to assembler code > > I'm not sure why anyone would want to do this; if you have another > language you can convert it to C code, and concentrate on what you are > doing. If you find that the C->assembly step can be improved that is > also useful. there are a few drawbacks to compiling to C though: one can only compile to C in contexts where they have a C compiler, which largely rules out things like JIT compilers; the time-to-comile may be somewhat worse (in cases where this is important); some language features are difficult to implement effectively in C (and standard C is annoyingly lacking in reflection features); ... so, it is not so clear-cut that one wouldn't want to compiler to ASM (or to some bytecode, which is run through a JIT). [Do you mean compiling to assembler, or compiling to machine code? They're different. -John]