This is the mail archive of the cgen@sources.redhat.com mailing list for the CGEN project.


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

Re: CGEN: RFA: CGEN_INT_INSN_P


Ben Elliston wrote:

> Dave,
>
>    I ran into a problem with the cgen-based gas/opcodes/binutils/sim port
>    that I am working on. The ISA has some 16 bit insns and some 32 bit
>    insns, so I set default-insn-word-bitsize=16, default-insn-bitsize=16
>    and base-insn-bitsize=16.
>
> Have you been able to determine the difference between all of these
> parameters?  I've lucked out so far, in that all of my ports allow them to
> be the same.  Perhaps if I understood it better, I could improve the
> documentation.

Hi Ben,

The problems don't seem to stem from all these parameters being the same. The
problems are being caused by base-insn-bitsize (16 bits in my case) not being
the same size as CGEN_INSN_INT (32 bits) combined with existence of insns of
different sizes. Basically, there are many places in CGEN where only the bits
represented by base-insn-bitsize get loaded into the integer, but then
CGEN goes on to access the rest of the fields anyway.

I've found another such problem in with the generation of decode.c which I am
trying to fix now.

Dave

Dave


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