This is the mail archive of the
cgen@sourceware.org
mailing list for the CGEN project.
Some CGEN problems
- From: "Kai Henningsen" <kai dot extern at googlemail dot com>
- To: cgen at sources dot redhat dot com
- Date: Sat, 19 Apr 2008 19:23:48 +0200
- Subject: Some CGEN problems
I'm playing with CGEN for a virtual cpu.
Maybe the largest problem (after the rather sparse documentation) is
that the pmacro system seems to be much weaker than GCC's iterator
system.
I've yet to figure out a way to iterate over two variables (such as
"integer opcodes" and "modes for integer opcodes"), or a way to handle
what GCC does with iterator attributes (such as the mapping from RTL
operands to opcode names). Right now, the best way I can think of is
to generate CGEN input with a Perl script ... but surely the whole
point of CGEN is that I shouldn't need that?!
This (and the growing list of stuff that I find that CGEN doesn't even
try to handle) makes me wonder if it might be easier to not use CGEN.
Of course, binutils documentation isn't any better. I thought GCC
documentation was sparse, but compared with these two, it's positively
encyclopedic!