This is the mail archive of the
cgen@sources.redhat.com
mailing list for the CGEN project.
frv suggestions
- From: Doug Evans <dje at sebabeach dot org>
- To: brolley at redhat dot com
- Cc: cgen at sources dot redhat dot com
- Date: Wed, 11 Jun 2003 10:26:10 -0700 (PDT)
- Subject: frv suggestions
- References: <20030611080838.A848BB536@mail.sebabeach.org> <3EE74E11.1040700@redhat.com>
Here's a couple of suggestions for the frv port.
1) I don't know if anyone maintaining it uses emacs,
but I'd highly recommend using ^L to delimit groups of
instructions. When skimming through source files, I find the
following extremely useful.
; one-liner describing this section
mumble ...
^L
; one-liner describing this section
mumble ...
^L
; one-liner describing this section
mumble ...
... and so on ...
If something is small enough one sometimes needn't bother.
But methinks frv.cpu is big enough that the above would be helpful.
frv.cpu already does this for hardware vs operands vs insns, etc.
But the "Instruction definitions" section is large enough that
I wonder if adding some more ^L's would make traversing it easier.
Just a thought. I only browse it rarely, so I don't know if going
to the trouble will pay off or not.
In emacs I can then do C-x [ and C-x ] to quickly traverse through
each section of the file and with the one-liner I can quickly see where I am.
2) To make the generated html more useful, you might want to
redefine the IDOC attribute to be something more resembling the frv,
and add the attribute to each instruction. This lets the html generator
categorize instructions and makes the instruction set more accessible
to the human reader.
I added some simple heuristics to make the result semi-usable
in the absence of explicitly provided IDOC attributes, but it breaks down,
for example, if all memory accesses are done via c-call's. :-)
It also breaks down on the arm when every alu op can set the pc. Blech.