Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update icache with bugfixes from injection testing #83

Open
wants to merge 1 commit into
base: astral
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions Bender.lock
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ packages:
dependencies:
- common_cells
axi:
revision: 9402c8a9ce0a7b5253c3c29e788612d771e8b5d6
version: 0.39.3
revision: 587355b77b8ce94dcd600efbd5d5bd118ff913a7
version: 0.39.4
Comment on lines +10 to +11
Copy link
Contributor

@yvantor yvantor Jan 4, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remember 0.39.4 has a killer bug, I saw in the upstream the release was modified to be the same as 0.39.5, but here we are pointing to the wrong commit (see here].

source:
Git: https://github.com/pulp-platform/axi.git
dependencies:
Expand Down Expand Up @@ -38,7 +38,7 @@ packages:
dependencies:
- common_cells
cluster_icache:
revision: 8114ab36fd446f76cd1e9f139f12a62ab1fb9a6a
revision: dd0e8f3497903a9ca99fc9f349d5a4f688ceb3ae
version: null
source:
Git: https://github.com/pulp-platform/cluster_icache.git
Expand All @@ -63,8 +63,8 @@ packages:
dependencies:
- hci
common_cells:
revision: 0d67563b6b592549542544f1abc0f43e5d4ee8b4
version: 1.35.0
revision: c27bce39ebb2e6bae52f60960814a2afca7bd4cb
version: 1.37.0
source:
Git: https://github.com/pulp-platform/common_cells.git
dependencies:
Expand Down
2 changes: 1 addition & 1 deletion Bender.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ dependencies:
mchan: { git: "https://github.com/pulp-platform/mchan.git", rev: 7f064f205a3e0203e959b14773c4afecf56681ab } # branch: yt/fix-parametrization
idma: { git: "https://github.com/pulp-platform/iDMA.git", rev: 437ffa9dac5dea0daccfd3e8ae604d4f6ae2cdf1 } # branch: master
hier-icache: { git: "https://github.com/pulp-platform/hier-icache.git", rev: "2886cb2a46cea3e2bd2d979b505d88fadfbe150c" } # branch: astral
cluster_icache: { git: "https://github.com/pulp-platform/cluster_icache.git", rev: "8114ab36fd446f76cd1e9f139f12a62ab1fb9a6a" } # michaero/branch: astral_cut_path
cluster_icache: { git: "https://github.com/pulp-platform/cluster_icache.git", rev: "dd0e8f3497903a9ca99fc9f349d5a4f688ceb3ae" } # branch: michaero/astral_reliability
cluster_peripherals: { git: "https://github.com/pulp-platform/cluster_peripherals.git", rev: 0b8e8ab } # branch: fc/hci-v2
axi: { git: "https://github.com/pulp-platform/axi.git", version: 0.39.3 }
timer_unit: { git: "https://github.com/pulp-platform/timer_unit.git", version: 1.0.2 }
Expand Down
36 changes: 36 additions & 0 deletions scripts/fault_injection_utils/pulp_extract_nets.tcl
Original file line number Diff line number Diff line change
Expand Up @@ -245,6 +245,42 @@ proc get_all_core_nets {core} {
return $all_signals
}

##########################
# Get all icache state #
##########################

proc get_all_icache_state {} {
set icache_base /pulp_cluster_tb/cluster_i/icache_top_i/i_snitch_icache

set l1_data_base $icache_base/gen_serial_lookup/i_lookup/i_data/i_tc_sram
set l1_tag_base $icache_base/gen_serial_lookup/i_lookup/gen_scm

set l1_data [list]
for {set i 0} {$i < [examine -radix dec $l1_data_base/NumWords]} {incr i} {
lappend l1_data $l1_data_base/sram\[$i\]
}
set l1_tag [list]
for {set i 0} {$i < [examine -radix dec $icache_base/SET_COUNT]} {incr i} {
for {set j 0} {$j < [examine -radix dec $l1_tag_base/g_sets\[$i\]/i_tag/N_SCM_REGISTERS]} {incr j} {
lappend l1_tag $l1_tag_base/g_sets\[$i\]/i_tag/block_ram_gen/MemContent_int\[$j\]
}
}

set l0_data [list]
set l0_tag [list]
for {set i 0} {$i < [examine -radix dec $icache_base/NR_FETCH_PORTS]} {incr i} {
for {set j 0} {$j < [examine -radix dec $icache_base/L0_LINE_COUNT]} {incr j} {
lappend l0_data $icache_base/gen_prefetcher\[$i\]/i_snitch_icache_l0/data\[$j\]
}
# Questa force does not work properly on arrays of structs, always forcing the first element instead of the one specified.
# Therefore, we limit our injections as well.
lappend l0_tag $icache_base/gen_prefetcher\[$i\]/i_snitch_icache_l0/tag\[0\].tag
lappend l0_tag $icache_base/gen_prefetcher\[$i\]/i_snitch_icache_l0/tag\[0\].vld
}

return [concat $l1_data $l1_tag $l0_data $l0_tag]
}

##################
# Memory signals #
##################
Expand Down
Loading