diff --git a/hw/ip/spatz_cc/src/spatz_cc.sv b/hw/ip/spatz_cc/src/spatz_cc.sv index d5119c85..02790f83 100644 --- a/hw/ip/spatz_cc/src/spatz_cc.sv +++ b/hw/ip/spatz_cc/src/spatz_cc.sv @@ -70,7 +70,7 @@ module spatz_cc parameter int unsigned NumSpatzOutstandingLoads = 0, // Enable V Extension parameter bit RVV = 1, - // Spatz paramaters + // Spatz parameters parameter int unsigned NumSpatzFPUs = 4, parameter int unsigned NumSpatzIPUs = 1, /// Add isochronous clock-domain crossings e.g., make it possible to operate diff --git a/hw/system/spatz_cluster/src/spatz_cluster.sv b/hw/system/spatz_cluster/src/spatz_cluster.sv index 381dc299..d2440ee6 100644 --- a/hw/system/spatz_cluster/src/spatz_cluster.sv +++ b/hw/system/spatz_cluster/src/spatz_cluster.sv @@ -69,6 +69,9 @@ module spatz_cluster parameter int unsigned NumIntOutstandingMem [NrCores] = '{default: '0}, /// Per-core Spatz outstanding loads parameter int unsigned NumSpatzOutstandingLoads [NrCores] = '{default: '0}, + // Spatz parameters + parameter int unsigned NumSpatzFPUs [NrCores] = '{default: '0}, + parameter int unsigned NumSpatzIPUs [NrCores] = '{default: '0}, /// ## Timing Tuning Parameters /// Insert Pipeline registers into off-loading path (response) parameter bit RegisterOffloadRsp = 1'b0, @@ -736,6 +739,8 @@ module spatz_cluster .XF8 (1'b1 ), .XF8ALT (1'b1 ), .IsoCrossing (1'b0 ), + .NumSpatzFPUs (NumSpatzFPUs[i] ), + .NumSpatzIPUs (NumSpatzIPUs[i] ), .NumIntOutstandingLoads (NumIntOutstandingLoads[i] ), .NumIntOutstandingMem (NumIntOutstandingMem[i] ), .NumSpatzOutstandingLoads(NumSpatzOutstandingLoads[i]), @@ -777,7 +782,7 @@ module spatz_cluster assign wide_axi_mst_req[SDMAMst] = axi_dma_req; assign axi_dma_res = wide_axi_mst_rsp[SDMAMst]; assign dma_events = dma_core_events; - end else begin: gen_no_dma_connection + end else begin: gen_no_dma_connection assign axi_dma_res = '0; end end diff --git a/hw/system/spatz_cluster/src/spatz_cluster_wrapper.sv.tpl b/hw/system/spatz_cluster/src/spatz_cluster_wrapper.sv.tpl index 4fb6fb87..b7ab6460 100644 --- a/hw/system/spatz_cluster/src/spatz_cluster_wrapper.sv.tpl +++ b/hw/system/spatz_cluster/src/spatz_cluster_wrapper.sv.tpl @@ -311,6 +311,8 @@ module ${cfg['name']}_wrapper localparam int unsigned NumIntOutstandingLoads [NumCores] = '{${core_cfg('num_int_outstanding_loads')}}; localparam int unsigned NumIntOutstandingMem [NumCores] = '{${core_cfg('num_int_outstanding_mem')}}; localparam int unsigned NumSpatzOutstandingLoads [NumCores] = '{${core_cfg('num_spatz_outstanding_loads')}}; + localparam int unsigned NumSpatzFPUs [NumCores] = '{${cfg['n_fpu']}}; + localparam int unsigned NumSpatzIPUs [NumCores] = '{${cfg['n_ipu']}}; spatz_cluster_pkg::spatz_axi_iwc_out_req_t axi_from_cluster_iwc_req; spatz_cluster_pkg::spatz_axi_iwc_out_resp_t axi_from_cluster_iwc_resp; @@ -507,6 +509,8 @@ module ${cfg['name']}_wrapper .NumIntOutstandingLoads (NumIntOutstandingLoads), .NumIntOutstandingMem (NumIntOutstandingMem), .NumSpatzOutstandingLoads (NumSpatzOutstandingLoads), + .NumSpatzFPUs (NumSpatzFPUs), + .NumSpatzIPUs (NumSpatzIPUs), .axi_in_req_t (axi_in_req_t), .axi_in_resp_t (axi_in_resp_t), .axi_out_req_t (spatz_cluster_pkg::spatz_axi_iwc_out_req_t), diff --git a/util/Makefrag b/util/Makefrag index c0b1ca3d..974e0007 100644 --- a/util/Makefrag +++ b/util/Makefrag @@ -6,8 +6,8 @@ # Root SHELL = /usr/bin/env bash -SPATZ_DIR := $(shell git rev-parse --show-toplevel 2>/dev/null || echo $$SPATZ_DIR) -ROOT_DIR := ${SPATZ_DIR} +SPATZ_DIR ?= $(shell git rev-parse --show-toplevel 2>/dev/null || echo $$SPATZ_DIR) +ROOT_DIR ?= ${SPATZ_DIR} # Binaries INSTALL_PREFIX ?= install