[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [f-cpu] snapshot QDCPOC+YGASM
On Thu, Aug 02, 2001 at 02:29:01AM +0200, Yann Guidon wrote:
> hi,
> i have attached the current version of my work.
>
> i have discovered troubles when i wanted to decode some
> instructions that do not fit byte boundaries for the subfields,
> ie : loadcons uses 4 bits that overlap the opcode.
Huh? That should not be a problem at all in C.
> my proposition is to reverse the order of all the bits
> in the manual. the instructions will be stored in big-endian
> so the opcode always appears at the first position in a hexdump.
> we had this kind of discussions 2 years ago and i think that the
> effort is not large. in fact it probably eases the encoding and
> the decoding.
In that point, the manual is confusing anyway. The bits are numbered
from left to right, implying that the least significant bit/byte is on
the left (contrary to usual western notational conventions which place
it on the right).
I have no problems with making the opcode either the LSByte or the MSByte
of the instruction, but we should stick with little-endian because
it's the default for the load and store instructions (without the `e'
flag set). That is, if an instruction is stored at address (A), the
MSByte (which is probably the opcode) is stored at (A+3), and the
immediately following instruction starts at (A+4).
--
Michael "Tired" Riepe <Michael.Riepe@stud.uni-hannover.de>
"All I wanna do is have a little fun before I die"
*************************************************************
To unsubscribe, send an e-mail to majordomo@seul.org with
unsubscribe f-cpu in the body. http://f-cpu.seul.org/