Skip to content

Commit

Permalink
[FPGA] Synthesis and latch fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
elisabethumblet committed Nov 14, 2023
1 parent 7358592 commit 575fa15
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 8 deletions.
2 changes: 1 addition & 1 deletion hardware/src/ara_soc.sv
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,7 @@ module ara_soc import axi_pkg::*; import ara_pkg::*; #(
);

`ifndef SPYGLASS
tc_sram #(
tc_sram_wrapper #(
.NumWords (L2NumWords ),
.NumPorts (1 ),
.DataWidth(AxiDataWidth),
Expand Down
4 changes: 3 additions & 1 deletion hardware/src/lane/simd_mul.sv
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ module simd_mul import ara_pkg::*; import rvv_pkg::*; #(
always_comb begin : p_mul
// Default assignment
result_o = '0;

r = '0;
unique case (op)
// Single-Width integer multiply instructions
VMUL: for (int l = 0; l < 1; l++) result_o[64*l +: 64] = mul_res.w128[l][63:0];
Expand Down Expand Up @@ -204,6 +204,7 @@ module simd_mul import ara_pkg::*; import rvv_pkg::*; #(
end: gen_mul

always_comb begin : p_mul
r = '0;
unique case (op)
// Single-Width integer multiply instructions
VMUL: for (int l = 0; l < 2; l++) result_o[32*l +: 32] = mul_res.w64[l][31:0];
Expand Down Expand Up @@ -278,6 +279,7 @@ module simd_mul import ara_pkg::*; import rvv_pkg::*; #(
end : gen_mul

always_comb begin : p_mul
r = '0;
unique case (op)
// Single-Width integer multiply instructions
VMUL: for (int l = 0; l < 8; l++) result_o[8*l +: 8] = mul_res.w16[l][7:0];
Expand Down
2 changes: 1 addition & 1 deletion hardware/src/lane/vector_regfile.sv
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ module vector_regfile import ara_pkg::*; #(
assign vrf_clk = clk_i;
`endif

tc_sram #(
tc_sram_wrapper #(
.NumWords (NumWords ),
.DataWidth(DataWidth),
.NumPorts (1 )
Expand Down
5 changes: 4 additions & 1 deletion openpiton/axi_noc_bridge.sv
Original file line number Diff line number Diff line change
Expand Up @@ -804,7 +804,7 @@ begin
end


always_ff@(posedge clk or negedge rst_n)
always_comb //@(posedge clk or negedge rst_n)
begin
flit_state_next = flit_state_f;
unique case (flit_state_f)
Expand Down Expand Up @@ -1010,6 +1010,9 @@ begin
`endif
flit_ready = 1'b1;
end
default: begin
flit_ready = 1'b0;
end
endcase
end

Expand Down
10 changes: 6 additions & 4 deletions openpiton/noc_response_axi.sv
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ always_comb begin
end

endmodule
module noc_response_axi #(
module noc_response_axi import wt_cache_pkg::*; #(
parameter AXI_DATA_WIDTH = 64,
`ifndef ARA_REQ2MEM
parameter MSG_TYPE_INVAL = 2'd0, // Invalid Message
Expand Down Expand Up @@ -84,7 +84,7 @@ module noc_response_axi #(

localparam LAST_TRANSFER_FLAG_WIDTH = 1;

typedef enum logic [2:0] {
typedef enum logic [1:0] {
NOC_IN_STATE_HEADER = 2'b00, // Header 0
NOC_IN_STATE_READ_DATA = 2'b01, // Data Lines
NOC_IN_STATE_STORE_ACK = 2'b10 // for the fifo read when store happens
Expand Down Expand Up @@ -194,7 +194,8 @@ end

if (AXI_DATA_WIDTH == 64) begin
always_comb begin
rdata_fifo_wdata = {valid_last_read_transfer, {<<8{noc_data_in}}};
//rdata_fifo_wdata = {valid_last_read_transfer, {<<8{noc_data_in}}};
rdata_fifo_wdata = {valid_last_read_transfer, swendian64(noc_data_in)};

rdata_fifo_wval = read_size ? (noc_in_count_f >= 0) && (noc_in_state_f == NOC_IN_STATE_READ_DATA) && noc_io_go :
read_word_select ? (noc_in_count_f == 1) && (noc_in_state_f == NOC_IN_STATE_READ_DATA) && noc_io_go :
Expand All @@ -209,7 +210,8 @@ else begin
else first_word <= first_word;
end
always_comb begin
rdata_fifo_wdata = {valid_last_read_transfer, {<<8{first_word, noc_data_in}}};
//rdata_fifo_wdata = {valid_last_read_transfer, {<<8{first_word, noc_data_in}}};
rdata_fifo_wdata = {valid_last_read_transfer, swendian64({first_word, noc_data_in})};

rdata_fifo_wval = (noc_in_count_f == 1) && (noc_in_state_f == NOC_IN_STATE_READ_DATA) && noc_io_go;
end
Expand Down

0 comments on commit 575fa15

Please sign in to comment.