This is the mail archive of the mailing list for the GCC project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

GCC backend for dummy ?


I have a pet project that involves a simplistic
processor design and an even simpler virtual
machine that uses this processor. As of today,
I have a working model of the machine and a
little assembler that I can use to make test
programs with.

What I'd like to do now is get GCC to output
code in this assembler, so I can make more
complex programs. I'm really not big on compilers,
but I understand I need to write a backend for
it that describes my processor and how to convert
RTL into the native assembler. (I also believe
I'll have to get GAS to assemble code for the
new processor at some point, but that might be
another problem).

I tried to find documentation to learn the
process, and I found a couple of examples that
deal with the .md files, but that's about it.
all the other docs I found assume that the
reader has a solid compiler design background
and knows at least a little bit about the design
of GCC itself. So my question is : is there any
howto or commented example for creating a GCC
backend somewhere (something in the vein of the
"skel" character driver example found in the Linux
device drivers book) ? if I could just see how
it's done with a simple example that highlights
most of the porting process, it'll make the
learning curve a little less steep for me.

Thanks in advance !

                (@ @)
Pierre-Philippe Coupard
Senior Software Engineer, Lineo, Inc.
Email :
Phone : (801) 426-5001 x 208

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]