From 02991927b2071f979f3307533d5876e3fbbdd855 Mon Sep 17 00:00:00 2001 From: Aditya Naik Date: Fri, 27 Aug 2021 13:10:46 -0400 Subject: Removed older ALU from Chisel file This was not needed --- components.scala | 28 ---------------------------- 1 file changed, 28 deletions(-) diff --git a/components.scala b/components.scala index 9942e3a..d92f4ec 100644 --- a/components.scala +++ b/components.scala @@ -71,34 +71,6 @@ class RegisterFile() extends Module { } -class ALU() extends Module { - val io = IO(new Bundle { - val op = Input(UInt(4.W)) - val in1 = Input(UInt(32.W)) - val in2 = Input(UInt(32.W)) - val out = Output(UInt(32.W)) - val output_valid = Output(Bool()) - }) - - io.out := 0.U - io.output_valid := false.B - when(io.op === 0.U) { - io.out := io.in1 & io.in2; - io.output_valid := true.B - }.elsewhen(io.op === 1.U) { - io.out := io.in1 | io.in2; - io.output_valid := true.B - }.elsewhen(io.op === 2.U) { - io.out := io.in1 + io.in2; - io.output_valid := true.B - }.elsewhen(io.op === 6.U) { - io.out := io.in1 - io.in2 - io.output_valid := true.B - }.otherwise { - io.output_valid := false.B - } -} - println(getVerilog(new ALU)) // ChiselStage.emitChirrtl(new RegisterFile()) -- cgit v1.2.3