[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Rep:Re: [f-cpu] new langage ?

> I really don't want to be tied to a single programming language. No
> matter what it's called or who invented it.
> In order to support arbitrary languages, we need a native code generator
> that transforms an intermediate code representation into F-CPU machine
> code, and maybe also performs machine-dependent optimizations. I suggest
> we concentrate on this piece and worry about the language-specific
> front-end (which generates the intermediate code) later.
> That is, we have two things to do:
> 	- define an appropriate (universally usable) intermediate code
> 	- write code that maps it to F-CPU instructions
So you really want to create your own compiler, you now that gcc actually does 
all what we need ? It scan/parse the code, then generate a abstract syntax 
tree and then use the back end specification to translate this tree into asm 
for this specific architecture.
	And this translation can do some optimisation. If you want more about gcc 
backend I think it's chapter 20 of its documentation.

To unsubscribe, send an e-mail to majordomo@seul.org with
unsubscribe f-cpu       in the body. http://f-cpu.seul.org/