please..can anyone help me to create the testbench for controller,datapath and alucontrol for the codes in attachment?it is hard to understand the codes so by doing some test bech hope it will help me to understand more..realy i'm a newbie..thank you

Hi, if you don't know anything about the language verilog, than start a very simple project. Try to describe a "OR", "AND", ... gate, several flip flops, counter, and so on. Write testbenches for all this simple tests. Than, and only than you can do this without problem and you feel save, take your module and start to write an testbench. If you have no idea how to describe a OR gate, counter, etc. than begin to read literature, otherwise you will fail completely!!! Regards

If you are new, why do you start with such a complex thing like a processor? Start with an blinking LED, even there are enough pitfalls for a newbie.

in fact this "minimips" is vey interesting code! My recommendation to qayyum salleh: If you are new to the subject and want to learn Verilog hands on - start with some blinking LEDs, reaction on switches, some easy combinatorial logic and register logic examples. If you want to continue towards more complex things - have a look at the website www.fpga4fun.com. Another very good resource for learning purposes is the minimalistic MCPU at opencores (just google for MCPU...) I rewrote it from its functional specs and that helped me a lot to learn how things work ;) Good Luck!