Commit 17502833 authored by Jens Korinth's avatar Jens Korinth
Browse files

Support PEs with multiple slaves

* assumption: control slave is first in address map; following a
  non-control slave / custom
* added function to compute number of slaves for a PE coordinate
* status core now checks number of slaves an increase slot ids acc.
parent b362690d
......@@ -117,6 +117,13 @@ namespace eval arch {
return $insts
}
# Retrieve AXI-MM interfaces of given instance of kernel kind and mode.
proc get_aximm_interfaces {kind inst {mode "Master"}} {
set name [format "target_ip_%02d_%03d" $kind $inst]
puts "Retrieving list of slave interfaces for $name ..."
return [tapasco::get_aximm_interfaces [get_bd_cell -hier -filter "NAME == $name"] $mode]
}
# Instantiates the memory interconnect hierarchy.
proc arch_create_mem_interconnects {composition outs} {
variable arch_mem_ports
......
......@@ -372,6 +372,16 @@ namespace eval tapasco {
}
}
# make map of IDs -> number of slave interfaces
set composition [tapasco::get_composition]
set no_kinds [llength [dict keys $composition]]
set no_slaves [list]
for {set i 0} {$i < $no_kinds} {incr i} {
lappend no_slaves [dict get $composition $i id]
lappend no_slaves [llength [arch::get_aximm_interfaces $i 0 "Slave"]]
}
puts " Slvs: $no_slaves"
# create the IP core
set inst [create_bd_cell -type ip -vlnv [dict get $stdcomps tapasco_status vlnv] $name]
# make properties list
......@@ -382,7 +392,7 @@ namespace eval tapasco {
if {$slot < 128} {
lappend props "[format CONFIG.C_SLOT_KERNEL_ID_%d [expr $slot + 1]]" "$i"
}
incr slot
incr slot [dict get $no_slaves $i]
}
# get version strings
set vversion [split [version -short] {.}]
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment