Skip to content

Commit 401ed93

Browse files
committed
Build multiple blackparrot cfg
Signed-off-by: Kamil Rakoczy <krakoczy@antmicro.com>
1 parent 4420228 commit 401ed93

11 files changed

Lines changed: 1351 additions & 23 deletions

.github/workflows/large-designs.yml

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -487,13 +487,18 @@ jobs:
487487
**/plot_*.svg
488488
489489
blackparrot_synth:
490-
name: Black Parrot (synthesis)
491490
runs-on: [self-hosted, Linux, X64]
492491
container: ubuntu:jammy
492+
strategy:
493+
matrix:
494+
vars: [ {cfg: e_bp_unicore_cfg, machine: n2-highmem-8}, {cfg: e_bp_multicore_1_cfg, machine: n2-highmem-8}, {cfg: e_bp_multicore_1_cce_ucode_cfg, machine: n2-highmem-8}, {cfg: e_bp_multicore_4_cfg, machine: n2-highmem-32}, {cfg: e_bp_multicore_4_cce_ucode_cfg, machine: n2-highmem-32} ]
495+
fail-fast: false
496+
name: Black Parrot (${{ matrix.vars.cfg }} - synthesis)
493497
env:
494498
CC: gcc-9
495499
CXX: g++-9
496500
DEBIAN_FRONTEND: noninteractive
501+
GHA_MACHINE_TYPE: ${{ matrix.vars.machine }}
497502

498503
steps:
499504
- uses: actions/checkout@v3
@@ -540,11 +545,12 @@ jobs:
540545
env:
541546
TARGET: uhdm/yosys/synth-blackparrot-build
542547
TEST_CASE: tests/black-parrot
548+
BLACKPARROT_CFG: ${{ matrix.vars.cfg }}
543549

544550
- uses: actions/upload-artifact@v2
545551
with:
546-
name: bp_unicore.edif
547-
path: uhdm-tests/black-parrot/black-parrot/bp_top/syn/bp_unicore.edif
552+
name: bp_${{ matrix.vars.cfg }}.edif
553+
path: UHDM-integration-tests/build/bp_${{ matrix.vars.cfg }}.edif
548554

549555
- name: Upload load graphs
550556
if: ${{ always() }}

.github/workflows/main.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,7 @@ jobs:
9090
- name: Build binaries
9191
run: |
9292
export PATH="/usr/lib/ccache:/usr/local/opt/ccache/libexec:$PATH"
93+
cd yosys && git apply ../0001-Add-typedef-support-to-detectSignWidthWorker.patch && cd -
9394
./build_binaries.sh
9495
# By default actions/upload-artifact@v2 do not preserve file permissions
9596
# tar directory to workaround this issue
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
diff --git a/frontends/ast/genrtlil.cc b/frontends/ast/genrtlil.cc
2+
index eaf6553ce..ee7121548 100644
3+
--- a/frontends/ast/genrtlil.cc
4+
+++ b/frontends/ast/genrtlil.cc
5+
@@ -841,6 +841,9 @@ void AstNode::detectSignWidthWorker(int &width_hint, bool &sign_hint, bool *foun
6+
}
7+
if (!id_ast)
8+
log_file_error(filename, location.first_line, "Failed to resolve identifier %s for width detection!\n", str.c_str());
9+
+ if (id_ast->type == AST_TYPEDEF) {
10+
+ id_ast = id_ast->children[0];
11+
+ }
12+
if (id_ast->type == AST_PARAMETER || id_ast->type == AST_LOCALPARAM || id_ast->type == AST_ENUM_ITEM) {
13+
if (id_ast->children.size() > 1 && id_ast->children[1]->range_valid) {
14+
this_width = id_ast->children[1]->range_left - id_ast->children[1]->range_right + 1;

uhdm-tests/black-parrot/Makefile.in

Lines changed: 18 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -2,20 +2,27 @@ curr_dir:=$(dir $(lastword $(MAKEFILE_LIST)))
22
###################
33
### BLACKPARROT ###
44
###################
5-
VENV_BLACKPARROT_SYNTH = ${root_dir}/venv-blackparrot-synth
65
BLACKPARROT = ${curr_dir}/black-parrot
6+
BLACKPARROT_PATCHES_DIR = ${curr_dir}/black-parrot-patches/black-parrot/
7+
BLACKPARROT_BASEJUMP = ${BLACKPARROT}/external/basejump_stl/
8+
BLACKPARROT_BASEJUMP_PATCHES_DIR = ${curr_dir}/black-parrot-patches/basejump_stl
9+
BLACKPARROT_CFG ?= e_bp_unicore_cfg
10+
BLACKPARROT_UHDM = ${root_dir}/build/surelog/bp_tethered.${BLACKPARROT_CFG}.none.parse/out/slpp_unit/surelog.uhdm
711

8-
${VENV_BLACKPARROT_SYNTH}:
9-
virtualenv ${VENV_BLACKPARROT_SYNTH}
10-
(. ${VENV_BLACKPARROT_SYNTH}/bin/activate)
12+
${BLACKPARROT_BASEJUMP}/.gitpatch:
13+
cd ${BLACKPARROT_BASEJUMP} && git apply ${BLACKPARROT_BASEJUMP_PATCHES_DIR}/*.patch && touch $@
1114

12-
uhdm/yosys/synth-blackparrot-build: clean-build | ${VENV_BLACKPARROT_SYNTH}
15+
${BLACKPARROT}/.gitpatch: | ${BLACKPARROT_BASEJUMP}/.gitpatch
16+
cd ${BLACKPARROT}/ && git apply ${BLACKPARROT_PATCHES_DIR}/*.patch && touch $@
17+
18+
${BLACKPARROT_UHDM}: clean-build | ${BLACKPARROT}/.gitpatch
19+
(export PATH=${root_dir}/../image/bin:${PATH} && \
20+
cd ${BLACKPARROT}/bp_top/syn/ && SURELOG_OPTS=-synth $(MAKE) parse.surelog CFG=${BLACKPARROT_CFG} RESULTS_PATH=${root_dir}/build)
21+
22+
uhdm/yosys/synth-blackparrot-build: | ${BLACKPARROT_UHDM}
1323
(export PATH=${root_dir}/../image/bin:${PATH} && \
14-
. ${VENV_BLACKPARROT_SYNTH}/bin/activate && \
15-
cd ${BLACKPARROT}/external/basejump_stl/ && git apply ${curr_dir}/0001-Replace-stream-op.patch && \
16-
cd ${BLACKPARROT}/ && git apply ${curr_dir}/0002-Use-typedef-instead-of-anonymous-enum.patch && \
17-
cd ${BLACKPARROT}/bp_top/syn/ && SURELOG_OPTS=-synth $(MAKE) parse.surelog CFG=e_bp_unicore_cfg && \
24+
cd ${root_dir}/build && \
1825
yosys -p "plugin -i systemverilog" \
19-
-p "read_uhdm ./results/surelog/bp_tethered.e_bp_unicore_cfg.none.parse/out/slpp_unit/surelog.uhdm" \
26+
-p "read_uhdm ${BLACKPARROT_UHDM}" \
2027
-p "synth_xilinx -iopad -family xc7" \
21-
-p "write_edif bp_unicore.edif")
28+
-p "write_edif bp_${BLACKPARROT_CFG}.edif")
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
From 0677d0f5156b5afe8f54286ea690144da0547baa Mon Sep 17 00:00:00 2001
2+
From: Kamil Rakoczy <krakoczy@antmicro.com>
3+
Date: Wed, 26 Apr 2023 09:21:38 +0200
4+
Subject: [PATCH 1/3] Replace enum logic with typedef
5+
6+
Signed-off-by: Kamil Rakoczy <krakoczy@antmicro.com>
7+
---
8+
bsg_cache/bsg_cache_dma_to_wormhole.v | 5 +++--
9+
1 file changed, 3 insertions(+), 2 deletions(-)
10+
11+
diff --git a/bsg_cache/bsg_cache_dma_to_wormhole.v b/bsg_cache/bsg_cache_dma_to_wormhole.v
12+
index 19e4fcf0..7959eb85 100644
13+
--- a/bsg_cache/bsg_cache_dma_to_wormhole.v
14+
+++ b/bsg_cache/bsg_cache_dma_to_wormhole.v
15+
@@ -137,13 +137,14 @@ module bsg_cache_dma_to_wormhole
16+
);
17+
18+
// send FSM
19+
- enum logic [2:0] {
20+
+ typedef enum logic [2:0] {
21+
SEND_RESET
22+
, SEND_READY
23+
, SEND_ADDR
24+
, SEND_MASK
25+
, SEND_DATA
26+
- } send_state_n, send_state_r;
27+
+ } state_t;
28+
+ state_t send_state_n, send_state_r;
29+
30+
31+
// Check if mask bits are all 1.
32+
--
33+
2.39.0
34+

uhdm-tests/black-parrot/0001-Replace-stream-op.patch renamed to uhdm-tests/black-parrot/black-parrot-patches/basejump_stl/0002-Replace-stream-op.patch

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,24 @@
1-
From 9b0e8a2bf8963357966da8fc8e06472777ac7484 Mon Sep 17 00:00:00 2001
1+
From 5f7f45c5bab2deec9b681a1cf3fdf197c40b77b6 Mon Sep 17 00:00:00 2001
22
From: Kamil Rakoczy <krakoczy@antmicro.com>
3-
Date: Thu, 20 Apr 2023 17:26:12 +0200
4-
Subject: [PATCH] Replace stream-op
3+
Date: Wed, 26 Apr 2023 09:22:04 +0200
4+
Subject: [PATCH 2/3] Replace stream op
55

66
Signed-off-by: Kamil Rakoczy <krakoczy@antmicro.com>
77
---
88
bsg_misc/bsg_scan.v | 4 +++-
99
1 file changed, 3 insertions(+), 1 deletion(-)
1010

1111
diff --git a/bsg_misc/bsg_scan.v b/bsg_misc/bsg_scan.v
12-
index 063e74ef..c5433edb 100644
12+
index 063e74ef..6d19b277 100644
1313
--- a/bsg_misc/bsg_scan.v
1414
+++ b/bsg_misc/bsg_scan.v
1515
@@ -66,7 +66,9 @@ module bsg_scan #(parameter `BSG_INV_PARAM(width_p)
1616

1717
// streaming operation; reverses bits
1818
if (lo_to_hi_p)
1919
- assign t[0] = {<< {i}};
20-
+ for (genvar i = width_p-1; i >= 0; i--) begin
21-
+ assign t[width_p-1-i] = t[i];
20+
+ for (genvar i = 0; i < $clog2(width_p); i=i+1) begin
21+
+ assign t[$clog2(width_p)-i-1] = t[i];
2222
+ end
2323
else
2424
assign t[0] = i;
Lines changed: 93 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,93 @@
1+
From 638f88f8ea7f28d8f10d502033214ca6cc8cc696 Mon Sep 17 00:00:00 2001
2+
From: Kamil Rakoczy <krakoczy@antmicro.com>
3+
Date: Wed, 26 Apr 2023 15:06:28 +0200
4+
Subject: [PATCH 3/3] WIP: start wires from index 0
5+
6+
Signed-off-by: Kamil Rakoczy <krakoczy@antmicro.com>
7+
---
8+
bsg_noc/bsg_mesh_stitch.v | 51 ++++++++++++++++++++++-----------------
9+
1 file changed, 29 insertions(+), 22 deletions(-)
10+
11+
diff --git a/bsg_noc/bsg_mesh_stitch.v b/bsg_noc/bsg_mesh_stitch.v
12+
index 6ccb8383..201dce61 100644
13+
--- a/bsg_noc/bsg_mesh_stitch.v
14+
+++ b/bsg_noc/bsg_mesh_stitch.v
15+
@@ -14,15 +14,22 @@ module bsg_mesh_stitch
16+
, x_max_p = "inv"
17+
, y_max_p = "inv"
18+
, nets_p = 1 // optional parameter that allows for multiple networks to be routed together
19+
+ //typedef enum logic[2:0] {P=3'd0, W, E, N, S} Dirs;
20+
+ // recalculate assuming W = 0 and S = 0
21+
+ , parameter logic [2:0] W2 = 0 /*W-W*/
22+
+ , parameter logic [2:0] E2 = E-W
23+
+ , parameter logic [2:0] S2 = 0 /*S-S*/
24+
+ , parameter logic [2:0] N2 = S-N /*S is larger*/
25+
+ , parameter logic [2:0] SW2 = S-W /*S is larger*/
26+
)
27+
- (input [y_max_p-1:0][x_max_p-1:0][nets_p-1:0][S:W][width_p-1:0] outs_i // for each node, each direction
28+
- , output [y_max_p-1:0][x_max_p-1:0][nets_p-1:0][S:W][width_p-1:0] ins_o
29+
+ (input [y_max_p-1:0][x_max_p-1:0][nets_p-1:0][SW:0][width_p-1:0] outs_i // for each node, each direction
30+
+ , output [y_max_p-1:0][x_max_p-1:0][nets_p-1:0][SW:0][width_p-1:0] ins_o
31+
32+
// these are the edge of the greater tile
33+
- , input [E:W][y_max_p-1:0][nets_p-1:0][width_p-1:0] hor_i
34+
- , output [E:W][y_max_p-1:0][nets_p-1:0][width_p-1:0] hor_o
35+
- , input [S:N][x_max_p-1:0][nets_p-1:0][width_p-1:0] ver_i
36+
- , output [S:N][x_max_p-1:0][nets_p-1:0][width_p-1:0] ver_o
37+
+ , input [E2:W2][y_max_p-1:0][nets_p-1:0][width_p-1:0] hor_i
38+
+ , output [E2:W2][y_max_p-1:0][nets_p-1:0][width_p-1:0] hor_o
39+
+ , input [N2:S2][x_max_p-1:0][nets_p-1:0][width_p-1:0] ver_i
40+
+ , output [N2:S2][x_max_p-1:0][nets_p-1:0][width_p-1:0] ver_o
41+
);
42+
43+
genvar r,c,net;
44+
@@ -32,30 +39,30 @@ module bsg_mesh_stitch
45+
46+
for (r = 0; r < y_max_p; r=r+1)
47+
begin: _r
48+
- assign hor_o[E][r][net] = outs_i[r][x_max_p-1][net][E];
49+
- assign hor_o[W][r][net] = outs_i[r][0 ][net][W];
50+
+ assign hor_o[E2-1][r][net] = outs_i[r][x_max_p-1][net][E2-1];
51+
+ assign hor_o[W2][r][net] = outs_i[r][0 ][net][W2];
52+
53+
for (c = 0; c < x_max_p; c=c+1)
54+
begin: _c
55+
- assign ins_o[r][c][net][S] = (r == y_max_p-1)
56+
- ? ver_i[S][c][net]
57+
- : outs_i[(r == y_max_p-1) ? r : r+1][c][net][N]; // ?: for warning
58+
- assign ins_o[r][c][net][N] = (r == 0)
59+
- ? ver_i[N][c][net]
60+
- : outs_i[r ? r-1: 0][c][net][S]; // ?: to eliminate warning
61+
- assign ins_o[r][c][net][E] = (c == x_max_p-1)
62+
- ? hor_i[E][r][net]
63+
- : outs_i[r][(c == x_max_p-1) ? c : (c+1)][net][W]; // ?: for warning
64+
- assign ins_o[r][c][net][W] = (c == 0)
65+
- ? hor_i[W][r][net]
66+
- : outs_i[r][c ? (c-1) :0][net][E]; // ?: to eliminate warning
67+
+ assign ins_o[r][c][net][N2] = (r == y_max_p-1)
68+
+ ? ver_i[N2][c][net]
69+
+ : outs_i[(r == y_max_p-1) ? r : r+1][c][net][S2]; // ?: for warning
70+
+ assign ins_o[r][c][net][S2] = (r == 0)
71+
+ ? ver_i[S2][c][net]
72+
+ : outs_i[r ? r-1: 0][c][net][N2]; // ?: to eliminate warning
73+
+ assign ins_o[r][c][net][E2-1] = (c == x_max_p-1)
74+
+ ? hor_i[E2-1][r][net]
75+
+ : outs_i[r][(c == x_max_p-1) ? c : (c+1)][net][W2]; // ?: for warning
76+
+ assign ins_o[r][c][net][W2] = (c == 0)
77+
+ ? hor_i[W2][r][net]
78+
+ : outs_i[r][c ? (c-1) :0][net][E2-1]; // ?: to eliminate warning
79+
end // block: c
80+
end // block: r
81+
82+
for (c = 0; c < x_max_p; c=c+1)
83+
begin: _c
84+
- assign ver_o[S][c][net] = outs_i[y_max_p-1][c][net][S];
85+
- assign ver_o[N][c][net] = outs_i[0 ][c][net][N];
86+
+ assign ver_o[N2][c][net] = outs_i[y_max_p-1][c][net][N2];
87+
+ assign ver_o[S2][c][net] = outs_i[0 ][c][net][S2];
88+
end
89+
end // block: _n
90+
91+
--
92+
2.39.0
93+

uhdm-tests/black-parrot/0002-Use-typedef-instead-of-anonymous-enum.patch renamed to uhdm-tests/black-parrot/black-parrot-patches/black-parrot/0001-Replace-enum-logic-with-typedef.patch

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
From 84c652451d9eb1fa59eca827c985907e08a7be76 Mon Sep 17 00:00:00 2001
1+
From 4bf24076d9e7c0b6a458c58be0d6881f43c6d770 Mon Sep 17 00:00:00 2001
22
From: Kamil Rakoczy <krakoczy@antmicro.com>
3-
Date: Thu, 20 Apr 2023 17:27:06 +0200
4-
Subject: [PATCH] Use typedef instead of anonymous enum
3+
Date: Wed, 26 Apr 2023 09:17:17 +0200
4+
Subject: [PATCH 1/4] Replace enum logic with typedef
55

66
Signed-off-by: Kamil Rakoczy <krakoczy@antmicro.com>
77
---
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
From 0a5300004fc90bae4b0dbc214ff331e5a25cd5a6 Mon Sep 17 00:00:00 2001
2+
From: Kamil Rakoczy <krakoczy@antmicro.com>
3+
Date: Wed, 26 Apr 2023 09:17:48 +0200
4+
Subject: [PATCH 2/4] Add workaround for unsupported typespec
5+
6+
Signed-off-by: Kamil Rakoczy <krakoczy@antmicro.com>
7+
---
8+
bp_common/src/include/bp_common_bedrock_if.svh | 6 +++++-
9+
1 file changed, 5 insertions(+), 1 deletion(-)
10+
11+
diff --git a/bp_common/src/include/bp_common_bedrock_if.svh b/bp_common/src/include/bp_common_bedrock_if.svh
12+
index ac7acf8f..5118d0ee 100644
13+
--- a/bp_common/src/include/bp_common_bedrock_if.svh
14+
+++ b/bp_common/src/include/bp_common_bedrock_if.svh
15+
@@ -196,10 +196,14 @@
16+
`declare_bp_bedrock_header_width(addr_width_mp, mem_fwd_payload_width_lp, mem_fwd) \
17+
`declare_bp_bedrock_header_width(addr_width_mp, mem_rev_payload_width_lp, mem_rev)
18+
19+
+ //declare_bp_bedrock_mem_payload_s macro defines `bp_bedrock_mem_fwd_payload_s` struct,
20+
+ //and creates typedef `bp_bedrock_mem_rev_payload_s` that is equal to
21+
+ //`bp_bedrock_mem_fwd_payload_s` but Surelog doesn't see it. Use
22+
+ //`bp_bedrock_mem_fwd_payload_s` directly for now.
23+
`define declare_bp_bedrock_mem_if(addr_width_mp, did_width_mp, lce_id_width_mp, lce_assoc_mp) \
24+
`declare_bp_bedrock_mem_payload_s(did_width_mp, lce_id_width_mp, lce_assoc_mp); \
25+
`declare_bp_bedrock_header_s(addr_width_mp, bp_bedrock_mem_fwd_payload_s, mem_fwd); \
26+
- `declare_bp_bedrock_header_s(addr_width_mp, bp_bedrock_mem_rev_payload_s, mem_rev) \
27+
+ `declare_bp_bedrock_header_s(addr_width_mp, bp_bedrock_mem_fwd_payload_s, mem_rev) \
28+
29+
`define declare_bp_bedrock_if_widths(addr_width_mp, payload_width_mp, name_mp) \
30+
, localparam ``name_mp``_msg_payload_width_lp = payload_width_mp \
31+
--
32+
2.39.0
33+
Lines changed: 86 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,86 @@
1+
From 7c93699a9c0002d110aec5c62843084ece7403ba Mon Sep 17 00:00:00 2001
2+
From: Kamil Rakoczy <krakoczy@antmicro.com>
3+
Date: Wed, 26 Apr 2023 15:04:59 +0200
4+
Subject: [PATCH 3/4] WIP: Replace stream operator without reverse
5+
6+
Signed-off-by: Kamil Rakoczy <krakoczy@antmicro.com>
7+
---
8+
bp_me/src/v/cce/bp_cce_dir_segment.sv | 2 +-
9+
bp_me/src/v/cce/bp_cce_pending_bits.sv | 4 ++--
10+
bp_me/src/v/cce/bp_cce_spec_bits.sv | 4 ++--
11+
bp_me/src/v/network/bp_me_addr_to_cce_id.sv | 2 +-
12+
bp_top/test/common/bp_nonsynth_host.sv | 2 +-
13+
5 files changed, 7 insertions(+), 7 deletions(-)
14+
15+
diff --git a/bp_me/src/v/cce/bp_cce_dir_segment.sv b/bp_me/src/v/cce/bp_cce_dir_segment.sv
16+
index 94abc422..20394392 100644
17+
--- a/bp_me/src/v/cce/bp_cce_dir_segment.sv
18+
+++ b/bp_me/src/v/cce/bp_cce_dir_segment.sv
19+
@@ -126,7 +126,7 @@ module bp_cce_dir_segment
20+
logic [lg_num_cce_lp-1:0] cce_id_lo;
21+
logic [hash_index_width_lp-1:0] set_id_lo;
22+
// NOTE: reverse the address to use the low order bits for striping cache blocks across CCEs
23+
- wire [lg_sets_lp-1:0] hash_addr_rev = { <<{addr_i[lg_block_size_in_bytes_lp+:lg_sets_lp]}};
24+
+ wire [lg_sets_lp-1:0] hash_addr_rev = addr_i[lg_block_size_in_bytes_lp+:lg_sets_lp]; // TODO: reverse order
25+
26+
bsg_hash_bank
27+
#(.banks_p(num_cce_p) // number of CCE's to spread way groups over
28+
diff --git a/bp_me/src/v/cce/bp_cce_pending_bits.sv b/bp_me/src/v/cce/bp_cce_pending_bits.sv
29+
index 517c79df..94edd948 100644
30+
--- a/bp_me/src/v/cce/bp_cce_pending_bits.sv
31+
+++ b/bp_me/src/v/cce/bp_cce_pending_bits.sv
32+
@@ -62,8 +62,8 @@ module bp_cce_pending_bits
33+
// Address to way group hashing
34+
// The address to use as input starts at addr_offset_p and is lg_cce_way_groups_lp bits in length
35+
logic [hash_idx_width_lp-1:0] r_wg_lo, w_wg_lo;
36+
- wire [lg_cce_way_groups_lp-1:0] r_addr_rev = {<< {r_addr_i[addr_offset_p+:lg_cce_way_groups_lp]}};
37+
- wire [lg_cce_way_groups_lp-1:0] w_addr_rev = {<< {w_addr_i[addr_offset_p+:lg_cce_way_groups_lp]}};
38+
+ wire [lg_cce_way_groups_lp-1:0] r_addr_rev = r_addr_i[addr_offset_p+:lg_cce_way_groups_lp];// TODO: reverse order
39+
+ wire [lg_cce_way_groups_lp-1:0] w_addr_rev = w_addr_i[addr_offset_p+:lg_cce_way_groups_lp];// TODO: reverse order
40+
logic [lg_num_way_groups_lp-1:0] r_wg, w_wg;
41+
42+
bsg_hash_bank
43+
diff --git a/bp_me/src/v/cce/bp_cce_spec_bits.sv b/bp_me/src/v/cce/bp_cce_spec_bits.sv
44+
index c0b87884..f6523067 100644
45+
--- a/bp_me/src/v/cce/bp_cce_spec_bits.sv
46+
+++ b/bp_me/src/v/cce/bp_cce_spec_bits.sv
47+
@@ -58,8 +58,8 @@ module bp_cce_spec_bits
48+
49+
// Address to way group hashing
50+
logic [hash_idx_width_lp-1:0] r_wg_lo, w_wg_lo;
51+
- wire [lg_cce_way_groups_lp-1:0] r_addr_rev = {<< {r_addr_i[addr_offset_p+:lg_cce_way_groups_lp]}};
52+
- wire [lg_cce_way_groups_lp-1:0] w_addr_rev = {<< {w_addr_i[addr_offset_p+:lg_cce_way_groups_lp]}};
53+
+ wire [lg_cce_way_groups_lp-1:0] r_addr_rev = r_addr_i[addr_offset_p+:lg_cce_way_groups_lp];// TODO: reverse order
54+
+ wire [lg_cce_way_groups_lp-1:0] w_addr_rev = w_addr_i[addr_offset_p+:lg_cce_way_groups_lp];// TODO: reverse order
55+
logic [lg_num_way_groups_lp-1:0] r_wg, w_wg;
56+
57+
bsg_hash_bank
58+
diff --git a/bp_me/src/v/network/bp_me_addr_to_cce_id.sv b/bp_me/src/v/network/bp_me_addr_to_cce_id.sv
59+
index d3100ed4..b8cd9e76 100644
60+
--- a/bp_me/src/v/network/bp_me_addr_to_cce_id.sv
61+
+++ b/bp_me/src/v/network/bp_me_addr_to_cce_id.sv
62+
@@ -48,7 +48,7 @@ module bp_me_addr_to_cce_id
63+
// at the cache block granularity
64+
logic [lce_sets_width_p-1:0] hash_addr_li;
65+
logic [lg_num_cce_lp-1:0] cce_dst_id_lo;
66+
- assign hash_addr_li = {<< {paddr_i[block_offset_lp+:lce_sets_width_p]}};
67+
+ assign hash_addr_li = paddr_i[block_offset_lp+:lce_sets_width_p]; //TODO: reverse order
68+
bsg_hash_bank
69+
#(.banks_p(num_cce_p) // number of CCE's to spread way groups over
70+
,.width_p(lce_sets_width_p) // width of address input
71+
diff --git a/bp_top/test/common/bp_nonsynth_host.sv b/bp_top/test/common/bp_nonsynth_host.sv
72+
index 16dd997f..e62db586 100644
73+
--- a/bp_top/test/common/bp_nonsynth_host.sv
74+
+++ b/bp_top/test/common/bp_nonsynth_host.sv
75+
@@ -204,7 +204,7 @@ module bp_nonsynth_host
76+
);
77+
78+
// Convert to little endian
79+
- wire [dword_width_gp-1:0] bootrom_data_reverse = {<<8{bootrom_data_lo}};
80+
+ wire [dword_width_gp-1:0] bootrom_data_reverse = bootrom_data_lo; // TODO: reverse order
81+
82+
logic [dword_width_gp-1:0] bootrom_final_lo;
83+
bsg_bus_pack
84+
--
85+
2.39.0
86+

0 commit comments

Comments
 (0)