Merge branch 'TestRottoConDeadLock' of chef.heaplab.deib.polimi.it:nnicolosi/Raptor into TestRottoConDeadLock

This commit is contained in:
ilgeco
2026-07-22 13:36:55 +02:00
31 changed files with 693 additions and 1443 deletions
@@ -18,6 +18,11 @@ namespace spatial {
namespace {
// Pressure means distinct weights exceed half the fleet's one-copy capacity.
// The reserved headroom conservatively avoids greedy capacity fragmentation;
// makespan, communication, instruction-path, and local-memory proxies remain stable.
constexpr size_t kHighCrossbarPressureCapacityDivisor = 2;
struct ScheduledTask {
size_t processor = std::numeric_limits<size_t>::max();
Time startTime = 0;
@@ -138,7 +143,7 @@ void verifyOctTableSize(size_t nodeCount, size_t processorCount) {
bool hasHighCrossbarPressure(const ComputeGraph& graph, size_t processorCount, size_t crossbarCapacity) {
if (crossbarCapacity > std::numeric_limits<size_t>::max() / processorCount)
return false;
const size_t threshold = processorCount * crossbarCapacity / 2;
const size_t threshold = processorCount * crossbarCapacity / kHighCrossbarPressureCapacityDivisor;
CrossbarUsage distinctWeights;
for (const ComputeGraphNode& node : graph.nodes) {
for (const CrossbarWeight& weight : node.crossbarUsage) {