[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [f-cpu] fcpu-iss

On Fri, Mar 12, 2004 at 11:28:44AM +0100, Pierre Tardy wrote:
> > Well, both (f)lex and libelf are freely available.
> Yes, or course, but installing these in our Solaris(tm) server is very time
> crunching..


	gunzip package.tar.gz
	tar xvf package.tar
	cd package-ver.si.on
	./configure --prefix=/where/you/want/it
	make install

Takes less than 5 minutes (for both packages).

> > I'm not going to incorporate your changes into fctools, if that is
> > what you want to know.  But I'll probably add hooks that allow people
> > to build a cycle-accurate emulator from the same source.
> You will read it in our conclusions, but we think that simulating pipeline
> effects will need a somewhat big change in the architecture of the ISS.

Sorry, I haven't read it yet.
Is there an english (or german) version now?

I am prepared to make that "big change", however.  It's not as big as
you think.  The trick is to use an event queue, as in a VHDL simulator.

> I think you should take care of our changes in emu.c and in fcpu_opcodes.
> in fcpu_opcodes, the disassembler return as a side effect, the registers that
> are used in the instruction (see the show function of our emumain.c)

I'll look at that.

> in emu.c We have added the hooks for a TLM (Transaction Level Model) ISS (what
> we have done).

Last time I looked, it was rather invasive (and pretty ugly, too).
In particular, it didn't allow different kinds of emulators to share
the emulator core.  That's a MUST since I don't want to maintain two
versions of the code.

I'll provide an interface in the next release.  The basic idea is
that the emulator core will call external hooks (that is, functions
provided by the caller) when any of the following situations arise:

	- a register's value is fetched but not valid yet
	- the current instruction triggers a prefetch operation
	- there is an exception (like divide-by-0)
	- there is a system call or trap
	- there is a memory operation

> In these two files, the modifications are small and the code is, ASFAIK, not
> reindented.. hum ;) 

At least...

> BTW, you use, for tables initialisation the syntax:
>         static const char *msgs[EX_number] = {
>                 [EX_ACCESS]    = "access rights violation"
> };
> It doesnt compile with g++. Is it C99 or something?

Yes, it's C99 (or C89 with GNU extensions).

I recommend that you compile the emulator pieces with a C compiler,
because that's what they were written for.

 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/