


Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!



entity reg_file is port ( A : in word; -- input data port Add_A : in nybble; -- register select for input A B, C : out word; -- output data ports Add_B, Add_C : in nybble; -- register select for -- outputs B and C load : in std_logic; -- load enable signal clear : in std_logic; -- asynchronous, negative logic -- clear signal clk : in std_logic); -- rising edge triggered clock end entity reg_file;
Figure 1 : Register file entity.
first should use behavioral techniques similar to those used in Project 2. Represent your registers as an array of words and use a process to update register contents and register file outputs. The second should Implement your design using structural techniques. Specifically, your architecture should include only instantiated entities and no behavioral code. You may use only devices defined in the KURM09 library to develop the structural register file.
Exercise 2 Implement a test bench for your register file to demonstrate correctness. Your test bench should include both a behavioral and struc- tural model for your register file. A process should drive the two models with the same inputs to show that they model the same system. The fol- lowing entity / architecture pair defined in figure 2 provides a template for your test system.
entity reg_file_test is end reg_file_test;
architecture mixed of reg_file_test is Define signals to drive and observe models begin -- mixed dut1: entity work.reg_file(beh) port map ( instantiate behavioral model ); dut2: entity work.reg_file(struct) port map ( instantiate structural model ); test: process begin -- process test Drive behavioral and structural models with the same input signals and compare outputs. end process test; end architecture mixed;
Figure 2 : Register file test bench.
Exercise 3 Using behavioral synthesis tools available in the laboratory, synthesize your register file to the Xilinx prototyping board. Using ChipScope, demonstrate your register file to your TA. Note that you may combine Problem 2 with Problem 4 and produce one demonstration involving both the register file and ALU.
Using components from the KURM09 synthesis library you will develop a structural and behavioral model of a combinational ALU to support the KURM09 instruction set. Your ALU should perform operations that support the mathematical and logical instructions as well as offset calculation for memory access and
the same inputs to show that they model the same system. Use a test harness similar to that given in Problem 1 to implement the test.
Exercise 6 Using behavioral synthesis tools available in the laboratory, synthesize your ALU to the Xilinx prototyping board. Using ChipScope, demonstrate your register file to your TA. Note that you may combine Problem 4 with Problem 2 and produce one demonstration involving both the register file and ALU.
Notes