Skip to content

Commit

Permalink
TRIAL - fix stuff for synth and remove popc and extfp
Browse files Browse the repository at this point in the history
  • Loading branch information
mp-17 committed Oct 11, 2024
1 parent d66d762 commit 2538b8a
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 19 deletions.
2 changes: 1 addition & 1 deletion hardware/src/ara_sequencer.sv
Original file line number Diff line number Diff line change
Expand Up @@ -231,7 +231,7 @@ module ara_sequencer import ara_pkg::*; import rvv_pkg::*; import cf_math_pkg::i
vreg_access_t [31:0] write_list_d, write_list_q;

// This function determines the VFU responsible for handling this operation.
function automatic vfu_e vfu(ara_op_e op = VADD);
function automatic vfu_e vfu(ara_op_e op);
unique case (op) inside
[VADD:VWREDSUM] : vfu = VFU_Alu;
[VMUL:VFWREDOSUM] : vfu = VFU_MFpu;
Expand Down
2 changes: 1 addition & 1 deletion hardware/src/ara_soc.sv
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ module ara_soc import axi_pkg::*; import ara_pkg::*; #(
// Support for floating-point data types
parameter fpu_support_e FPUSupport = FPUSupportHalfSingleDouble,
// External support for vfrec7, vfrsqrt7
parameter fpext_support_e FPExtSupport = FPExtSupportEnable,
parameter fpext_support_e FPExtSupport = FPExtSupportDisable,
// Support for fixed-point data types
parameter fixpt_support_e FixPtSupport = FixedPointEnable,
// AXI Interface
Expand Down
2 changes: 1 addition & 1 deletion hardware/src/lane/lane_sequencer.sv
Original file line number Diff line number Diff line change
Expand Up @@ -564,7 +564,7 @@ module lane_sequencer import ara_pkg::*; import rvv_pkg::*; import cf_math_pkg::
// Extra elements to ask, because of the stride
logic [$clog2(8*NrLanes)-1:0] extra_stride;
// Need one bit more than vl, since we will also add the stride contribution
logic [$size(pe_req.vl):0] vl_tot;
logic [$bits(pe_req.vl):0] vl_tot;

// We need to trim full words from the start of the vector that are not used
// as operands by the slide unit.
Expand Down
21 changes: 5 additions & 16 deletions hardware/src/masku/masku.sv
Original file line number Diff line number Diff line change
Expand Up @@ -321,23 +321,12 @@ module masku import ara_pkg::*; import rvv_pkg::*; #(
// Remaining elements of the current instruction in the commit phase
vlen_t commit_cnt_d, commit_cnt_q;

// Population count for vcpop.m instruction
popcount #(
.INPUT_WIDTH (DataWidth*NrLanes)
) i_popcount (
.data_i (vcpop_operand),
.popcount_o(popcount )
);
// vpopc substitute
assign popcount = vcpop_operand[$clog2(DataWidth*NrLanes):0];

// Trailing zero counter
lzc #(
.WIDTH(DataWidth*NrLanes),
.MODE (0)
) i_clz (
.in_i (vcpop_operand),
.cnt_o (vfirst_count ),
.empty_o (vfirst_empty )
);
// vfirst substitute
assign vfirst_count = vcpop_operand[$clog2(DataWidth*NrLanes)-1:0];
assign vfirst_empty = vcpop_operand[0];

always_comb begin: p_mask_alu
alu_result = '0;
Expand Down

0 comments on commit 2538b8a

Please sign in to comment.