mirror of
https://github.com/pConst/basic_verilog.git
synced 2025-01-14 06:42:54 +08:00
Update formatting
This commit is contained in:
parent
0475ea0398
commit
f0edcd3af0
8
lifo.sv
8
lifo.sv
@ -47,8 +47,6 @@ module lifo #( parameter
|
|||||||
// "FALSE" - normal fifo mode
|
// "FALSE" - normal fifo mode
|
||||||
|
|
||||||
DEPTH = 8, // max elements count == DEPTH, DEPTH MUST be power of 2
|
DEPTH = 8, // max elements count == DEPTH, DEPTH MUST be power of 2
|
||||||
DEPTH_W = $clog2(DEPTH)+1, // elements counter width, extra bit to store
|
|
||||||
// "fifo full" state, see cnt[] variable comments
|
|
||||||
|
|
||||||
DATA_W = 32 // data field width
|
DATA_W = 32 // data field width
|
||||||
)(
|
)(
|
||||||
@ -72,6 +70,11 @@ module lifo #( parameter
|
|||||||
output logic fail
|
output logic fail
|
||||||
);
|
);
|
||||||
|
|
||||||
|
// elements counter width, extra bit to store
|
||||||
|
// "fifo full" state, see cnt[] variable comments
|
||||||
|
localparam DEPTH_W = $clog2(DEPTH+1);
|
||||||
|
|
||||||
|
|
||||||
// lifo data
|
// lifo data
|
||||||
logic [DEPTH-1:0][DATA_W-1:0] data = '0;
|
logic [DEPTH-1:0][DATA_W-1:0] data = '0;
|
||||||
|
|
||||||
@ -145,3 +148,4 @@ always_comb begin
|
|||||||
end
|
end
|
||||||
|
|
||||||
endmodule
|
endmodule
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user