blob: b38e0e3841464e23978581937dd962dbfe29cd8a (
plain)
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
|
`include "gfx/gfx_defs.sv"
module gfx_fp_fix
(
input logic clk,
input fp in,
input logic stall,
output fixed out
);
`ifndef VERILATOR
ip_fp_fix ip_fix
(
.a(in),
.q(out),
.en(!stall),
.areset(0),
.*
);
`else
fp pop;
assign out = $c("taller::fp_fix(", pop, ")");
gfx_pipes #(.WIDTH($bits(in)), .DEPTH(`FP_FIX_STAGES)) pipes
(
.out(pop),
.*
);
`endif
endmodule
|