Answered step by step
Verified Expert Solution
Question
1 Approved Answer
In this lab, you are given an arithmetic logic unit ( ALU ) design, which you are to test. The design has some bugs in
In this lab, you are given an arithmetic logic unit ALU design, which you are to test. The design has
some bugs in it You will design a testbench to test the functions of the ALU to find the bugs. You will
also revise the sequential logic D flipflops and create testbench for it
ALU Overview
An ALU performs basic arithmetic and logic operations. Examples of arithmetic operations are addition,
subtraction, multiplication, and division. Examples of logic operations are comparisons of values such
as NOT, AND, and OR This ALU has bit inputs A and B for operands, a bit input ALU Sel for
selecting the operation, a bit output ALU Out, and a bit output CarryOut. The datapath is just
bits wide to allow for easy coverage testing of the different operations. The operations of the ALU are
specified in the table below.
ALU Sel ALU Operation
ALU Out A B
ALU Out A B
ALU Out A B
ALU Out A B
ALU Out A
ALU Out A
ALU Out A rotated left by
ALU Out A rotated right by
ALU Out A and B
ALU Out A or B
ALU Out A xor B
ALU Out A nor B
ALU Out A nand B
ALU Out A xnor B
ALU Out if AB else
ALU Out if AB else
Note: Check canvas for some review slides on Verilog operators.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started