-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathm8_le.v
More file actions
42 lines (37 loc) · 1.09 KB
/
Copy pathm8_le.v
File metadata and controls
42 lines (37 loc) · 1.09 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
`timescale 1ns / 1ps
//////////////////////////////////////////////////////////////////////////////////
// Company:
// Engineer:
//
// Create Date: 10/31/2017 12:16:07 PM
// Design Name:
// Module Name: m8_le
// Project Name:
// Target Devices:
// Tool Versions:
// Description:
//
// Dependencies:
//
// Revision:
// Revision 0.01 - File Created
// Additional Comments:
//
//////////////////////////////////////////////////////////////////////////////////
module m8_le(
input [7:0] in,
input [2:0] sel,
input e,
output o
);
wire [7:0] c;
assign c[0] = (~sel[2] & ~sel[1] & ~sel[0] * in[0]);
assign c[1] = (~sel[2] & ~sel[1] & sel[0] * in[1]);
assign c[2] = (~sel[2] & sel[1] & ~sel[0] * in[2]);
assign c[3] = (~sel[2] & sel[1] & sel[0] * in[3]);
assign c[4] = (sel[2] & ~sel[1] & ~sel[0] * in[4]);
assign c[5] = (sel[2] & ~sel[1] & sel[0] * in[5]);
assign c[6] = (sel[2] & sel[1] & ~sel[0] * in[6]);
assign c[7] = (sel[2] & sel[1] & sel[0] * in[7]);
assign o = e & (c[0] | c[1] | c[2] | c[3] | c[4] | c[5] | c[6] | c[7]);
endmodule