How can I translate this code http://www.jwdt.com/~paysan/4stack.html to assembler? Someone studying similar realization? I would like to make a full emulator of this processor in assembly language. But I do not know where to start.
Try writing a single stack first, allocate a block of memory, allocate a pointer to locate it then simulate what a PUSH and POP instruction do, a PUSH writes the data to memory and changes the pointer to point to it, a POP does it in reverse.
Hi! Thank you, from that already started, I'll write here later :dance:
The scheme was not complicated. But questions in the course of programming. How do I connect x86 model and model type VLIW together? This course is already in a certain processor, in which processor core with 4 stack, and the shell of ordinary processors. Thus there is a bridge, which can run as a command processor VLIW, also with the CISC and RISC commands?
Another question, how then can we realize the parallel execution of code, without using the API WIN Threads? How can I choose whether to do a forward one that should be fulfilled now. Thank you!
Short of writing uyour own operating system you can't run threads without the Windows API functions to do this.
How about _beginthread/_beginthreadex :
http://msdn.microsoft.com/en-us/library/kdzttdcb(VS.80).aspx
it would seem that those functions eventually use API calls, no ?
I read a bit of the 4 stack model papers (though not much as I find it only moderately interesting) and from what I saw you will probably need to implement it in some flavor of VHDL, not an easy or inexpensive task. You can start looking for a Windows based VHDL compiler at model.com, it may be able to use the Verilog implementation on the site.
http://model.com/
Edgar
Quote from: dedndave on January 25, 2010, 01:44:19 PM
it would seem that those functions eventually use API calls, no ?
Haha.. so it does..
it could be written with masm - although - no way to parallel process without using threads
i don't really think that has to be a requirement
it is an emulator, so it is not like you expect it to be fast - lol
i would think it would be very similar to an interpreter
if i had to do it, i think i would get the basics set up with a few instructions (push, pop, add, sub, call/ret, jmp)
once you have that up and running, it is a matter of adding instructions to the list
depending on how large the instruction sets are, it could be quite a task :bg
Hi,
As it is an emulator, you could process things that are
intended to be in parallel processors in a strict round-
robin fashion. Or you could process multiple results as
a very long array of boolean valuse. That could simulate
multiple processes in parallel.
Regards,
Steve N.