This is the mail archive of the
cgen@sources.redhat.com
mailing list for the CGEN project.
cgen bug with larger-than-normal instructions?
- To: matthew green <mrg at cygnus dot com>
- Subject: cgen bug with larger-than-normal instructions?
- From: Doug Evans <dje at transmeta dot com>
- Date: Thu, 14 Sep 2000 17:06:37 -0700 (PDT)
- Cc: cgen at sources dot redhat dot com
- References: <23006.968974248@cygnus.com>
matthew green writes:
> i am doing a sim port for an architecture that has 16 bit insns for
> all but the 16-bit & 32-bit immediately load insns, which are 32-bits
> & 48-bits long each, with the immediate value placed after the insn.
>
> currently, cgen produces code that fails to compile:
>
> decode.cxx:1457: implicit declaration of function `int GETIMEMUHI(...)'
>
> this function is currently missing from cgen-cpu.h, but even after i
> add it there, the problem persists. i believe the generate code is
> wrong, and (with an insight from bje) i have developed the following
> patch. it makes two changes to cgen itself:
>
> - call GETIMEM* as "current_cpu->GETIMEM*"
This is a sid-ism and as such doesn't belong in utils-cgen.scm.
How do the other sid ports invoke GETIMEM?
> - first argument of GETIMEM*() is "pc"
>
> this allows my decoder to build, but i haven't tested that it works
> yet (i have now pages of errors for sem.cxx to deal with).
I don't quite follow why adding "pc" is necessary.