Skip to content

Commit d3c5f33

Browse files
committed
[LINT] trailing spaces, unuseful comments
1 parent a270f03 commit d3c5f33

21 files changed

Lines changed: 37 additions & 60 deletions

File tree

hw/ip/snitch/src/riscv_instr.sv

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1338,5 +1338,4 @@ package riscv_instr;
13381338
localparam logic [11:0] CSR_MHPMCOUNTER29H = 12'hb9d;
13391339
localparam logic [11:0] CSR_MHPMCOUNTER30H = 12'hb9e;
13401340
localparam logic [11:0] CSR_MHPMCOUNTER31H = 12'hb9f;
1341-
13421341
endpackage

hw/ip/snitch/src/snitch.sv

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2371,7 +2371,6 @@ module snitch import snitch_pkg::*; import riscv_instr::*; #(
23712371
riscv_instr::VREDMINU_VS,
23722372
riscv_instr::VREDMAX_VS,
23732373
riscv_instr::VREDMAXU_VS,
2374-
// CMY: add VMANDNOT VMAND VMOR VMXOR VMORNOT VMNAND VMNOR VMXNOR, 8 masking instructions
23752374
riscv_instr::VMANDN_MM,
23762375
riscv_instr::VMAND_MM,
23772376
riscv_instr::VMOR_MM,
@@ -2380,7 +2379,6 @@ module snitch import snitch_pkg::*; import riscv_instr::*; #(
23802379
riscv_instr::VMNAND_MM,
23812380
riscv_instr::VMNOR_MM,
23822381
riscv_instr::VMXNOR_MM,
2383-
//----------------------------------------------------------
23842382
riscv_instr::VMSEQ_VV,
23852383
riscv_instr::VMSEQ_VI,
23862384
riscv_instr::VMSNE_VV,

hw/ip/spatz/src/spatz.sv

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -458,7 +458,7 @@ module spatz import spatz_pkg::*; import rvv_pkg::*; import fpnew_pkg::*; #(
458458
.vfu_rsp_o (vfu_rsp ),
459459
// VRF
460460
.vrf_waddr_o (vrf_waddr[VFU_VD_WD] ),
461-
.vrf_wdata_o (vrf_wdata[VFU_VD_WD] ), // N_FU*ELEN bits
461+
.vrf_wdata_o (vrf_wdata[VFU_VD_WD] ),
462462
.vrf_we_o (sb_we[VFU_VD_WD] ),
463463
.vrf_wbe_o (vrf_wbe[VFU_VD_WD] ),
464464
`ifdef BUF_FPU

hw/ip/spatz/src/spatz_controller.sv

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -199,7 +199,7 @@ module spatz_controller
199199
logic req_buffer_ready, req_buffer_valid, req_buffer_pop;
200200

201201
// One element wide instruction buffer
202-
fall_through_register #( // a fifo.
202+
fall_through_register #(
203203
.T(spatz_req_t)
204204
) i_req_buffer (
205205
.clk_i (clk_i ),
@@ -431,12 +431,11 @@ module spatz_controller
431431
scoreboard_d[spatz_req.id].deps[write_table_d[spatz_req.vd].id] |= write_table_d[spatz_req.vd].valid;
432432
read_table_d[spatz_req.vd] = {spatz_req.id, 1'b1};
433433
end
434-
// CMY: tackling v0 RAW hazard-------------------------------------------------------
434+
// tackling v0 RAW hazard
435435
if (!spatz_req.op_arith.vm) begin
436436
scoreboard_d[spatz_req.id].deps[write_table_d[0].id] |= write_table_d[0].valid;
437437
read_table_d[0] = {spatz_req.id, 1'b1};
438438
end
439-
//--------------------------------------------------------------------------------------
440439

441440
// WAW and WAR hazards
442441
if (spatz_req.use_vd) begin
@@ -561,7 +560,7 @@ module spatz_controller
561560
running_insn_d = running_insn_q;
562561

563562
// New instruction!
564-
if (spatz_req_valid && spatz_req.ex_unit != CON) // declare a new instruction
563+
if (spatz_req_valid && spatz_req.ex_unit != CON)
565564
running_insn_d[next_insn_id] = 1'b1;
566565

567566
// Finished a instruction

hw/ip/spatz/src/spatz_decoder.sv

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -274,7 +274,6 @@ module spatz_decoder
274274
riscv_instr::VREDMINU_VS,
275275
riscv_instr::VREDMAX_VS,
276276
riscv_instr::VREDMAXU_VS,
277-
// CMY: add VMANDNOT VMAND VMOR VMXOR VMORNOT VMNAND VMNOR VMXNOR, 8 masking instructions
278277
riscv_instr::VMANDN_MM,
279278
riscv_instr::VMAND_MM,
280279
riscv_instr::VMOR_MM,
@@ -283,7 +282,6 @@ module spatz_decoder
283282
riscv_instr::VMNAND_MM,
284283
riscv_instr::VMNOR_MM,
285284
riscv_instr::VMXNOR_MM,
286-
//-------------------------------------------------------------
287285
riscv_instr::VMSEQ_VV,
288286
riscv_instr::VMSEQ_VX,
289287
riscv_instr::VMSEQ_VI,
@@ -358,7 +356,7 @@ module spatz_decoder
358356
automatic vreg_t arith_s1 = decoder_req_i.instr[19:15];
359357
automatic vreg_t arith_s2 = decoder_req_i.instr[24:20];
360358
automatic vreg_t arith_d = decoder_req_i.instr[11:7];
361-
automatic logic arith_vm = decoder_req_i.instr[25]; //Vector Arithmetic Masking Enable bit
359+
automatic logic arith_vm = decoder_req_i.instr[25];
362360

363361
spatz_req.op_arith.vm = arith_vm;
364362
spatz_req.op_sld.vm = arith_vm;
@@ -837,7 +835,6 @@ module spatz_decoder
837835
end
838836
end
839837

840-
// CMY: Mask operations
841838
riscv_instr::VMANDN_MM: begin
842839
spatz_req.op = VMANDNOT;
843840
end

hw/ip/spatz/src/spatz_ipu.sv

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -478,7 +478,6 @@ module spatz_ipu import spatz_pkg::*; import rvv_pkg::vew_e; #(
478478
///////////////
479479

480480
// Collect results from the SIMD lanes
481-
// each lane is responsible for calculating one element.
482481
always_comb begin : collector
483482
unique case (sew)
484483
rvv_pkg::EW_8 : begin

hw/ip/spatz/src/spatz_pkg.sv.tpl

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -120,10 +120,6 @@ package spatz_pkg;
120120
typedef logic [VFURespAddrWidth-1:0] vfu_rsp_addr_t;
121121
typedef logic [N_FU*ELENB-1:0] vrf_be_t;
122122
typedef logic [N_FU*ELEN-1:0] vrf_data_t;
123-
// ELEN = 64
124-
// The VRF is centralized and serves all functional units.
125-
// Each VRF port is 64F-bit wide. F denotes the number of FPUs.
126-
// the FU here doesn't refer to Functioan Units. N_FU=max{N_IPU,N_FPU}
127123

128124
// Instruction ID
129125
typedef logic [$clog2(NrParallelInstructions)-1:0] spatz_id_t;

hw/ip/spatz/src/spatz_simd_lane.sv

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -220,14 +220,14 @@ module spatz_simd_lane import spatz_pkg::*; import rvv_pkg::vew_e; #(
220220
VSUB, VRSUB, VNMSAC, VNMSUB, VSBC: simd_result = subtractor_result[Width-1:0];
221221
VMIN, VMINU : simd_result = $signed({op_s1_i[Width-1] & is_signed_i, op_s1_i}) <= $signed({op_s2_i[Width-1] & is_signed_i, op_s2_i}) ? op_s1_i : op_s2_i;
222222
VMAX, VMAXU : simd_result = $signed({op_s1_i[Width-1] & is_signed_i, op_s1_i}) > $signed({op_s2_i[Width-1] & is_signed_i, op_s2_i}) ? op_s1_i : op_s2_i;
223-
VAND, VMAND : simd_result = op_s1_i & op_s2_i; // CMY: add masking support
224-
VOR , VMOR : simd_result = op_s1_i | op_s2_i; // like above
225-
VXOR, VMXOR : simd_result = op_s1_i ^ op_s2_i; // like above
226-
VMANDNOT : simd_result = ~op_s1_i & op_s2_i; // like above
227-
VMORNOT : simd_result = ~op_s1_i | op_s2_i; // like above
228-
VMNAND : simd_result = ~(op_s1_i & op_s2_i); // like above
229-
VMNOR : simd_result = ~(op_s1_i | op_s2_i); // like above
230-
VMXNOR : simd_result = ~(op_s1_i ^ op_s2_i); // like above
223+
VAND, VMAND : simd_result = op_s1_i & op_s2_i;
224+
VOR , VMOR : simd_result = op_s1_i | op_s2_i;
225+
VXOR, VMXOR : simd_result = op_s1_i ^ op_s2_i;
226+
VMANDNOT : simd_result = ~op_s1_i & op_s2_i;
227+
VMORNOT : simd_result = ~op_s1_i | op_s2_i;
228+
VMNAND : simd_result = ~(op_s1_i & op_s2_i);
229+
VMNOR : simd_result = ~(op_s1_i | op_s2_i);
230+
VMXNOR : simd_result = ~(op_s1_i ^ op_s2_i);
231231
VSLL : simd_result = shift_operand << shift_amount;
232232
VSRL : simd_result = shift_operand >> shift_amount;
233233
VSRA : simd_result = $signed(shift_operand) >>> shift_amount;

hw/ip/spatz/src/spatz_vrf.sv

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ module spatz_vrf
2020
input vrf_addr_t [NrWritePorts-1:0] waddr_i,
2121
input vrf_data_t [NrWritePorts-1:0] wdata_i,
2222
input logic [NrWritePorts-1:0] we_i,
23-
input vrf_be_t [NrWritePorts-1:0] wbe_i, // 32 bits* 3 WritePorts
23+
input vrf_be_t [NrWritePorts-1:0] wbe_i,
2424
output logic [NrWritePorts-1:0] wvalid_o,
2525
`ifdef BUF_FPU
2626
// Signal to track if result can be buffered or not
@@ -45,7 +45,7 @@ module spatz_vrf
4545
// Typedefs //
4646
//////////////
4747

48-
typedef logic [$bits(vrf_addr_t)-$clog2(NrVRFBanks)-1:0] vregfile_addr_t; // divide the addresses into banks.
48+
typedef logic [$bits(vrf_addr_t)-$clog2(NrVRFBanks)-1:0] vregfile_addr_t;
4949

5050
function automatic logic [$clog2(NrWordsPerBank)-1:0] f_vreg(vrf_addr_t addr);
5151
f_vreg = addr[$clog2(NrVRFWords)-1:$clog2(NrVRFBanks)];

hw/system/spatz_cluster/Makefile

Lines changed: 6 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -46,14 +46,9 @@ endif
4646
include $(ROOT)/util/Makefrag
4747

4848
# QuestaSim
49-
#VSIM = questa-2021.3-kgf vsim
50-
#VLOG = questa-2021.3-kgf vlog
51-
#VSIM_HOME = /usr/pack/questa-2021.3-kgf/questasim
52-
VSIM = vsim
53-
VLOG = vlog
54-
VSIM_HOME = /sw/CAD/Siemens/questa/2024.3/questasim
55-
#CMY modified
56-
49+
VSIM = questa-2021.3-kgf vsim
50+
VLOG = questa-2021.3-kgf vlog
51+
VSIM_HOME = /usr/pack/questa-2021.3-kgf/questasim
5752

5853
VSIM_FLAGS += -t 1ps
5954
VSIM_FLAGS += -do "log -r /*; source ${SPATZ_CLUSTER_DIR}/script/vsim/wave.tcl; run -a"
@@ -226,14 +221,11 @@ clean.vcs:
226221
# SPYGLASS #
227222
############
228223

229-
#SNPS_SG ?= spyglass-2022.06
230-
SNPS_SG ?= spyglass #Mamothones
224+
SNPS_SG ?= spyglass-2022.06
231225

232226
.PHONY: lint lint/tmp/files
233227
lint: generate lint/tmp/files lint/sdc/func.sdc lint/script/lint.tcl
234-
# cd lint && $(SNPS_SG) sg_shell -tcl script/lint.tcl
235-
cd lint && sg_shell -tcl script/lint.tcl
236-
228+
cd lint && $(SNPS_SG) sg_shell -tcl script/lint.tcl
237229

238230
lint/tmp/files: ${BENDER}
239231
mkdir -p lint/tmp
@@ -328,4 +320,4 @@ help:
328320
@echo -e "Additional useful targets from the included Makefrag:"
329321
@echo -e "${Blue}traces ${Black}Generate the better readable traces in .logs/trace_hart_<hart_id>.txt with spike-dasm."
330322
@echo -e ""
331-
@echo -e "${Blue}spatz.gendata ${Black}Generate data for all spatz benchmarks using gen_data.py with all config files."
323+
@echo -e "${Blue}spatz.gendata ${Black}Generate data for all spatz benchmarks using gen_data.py with all config files."

0 commit comments

Comments
 (0)