From ab11bd1216cded591382ed01b6f5ce0f55a6de46 Mon Sep 17 00:00:00 2001 From: Fredrik Svedberg Date: Mon, 15 Feb 2021 15:36:05 +0100 Subject: Make HillClimb allocation reproducible Made HillClimb allocation results reproducible between runs. Signed-off-by: Fredrik Svedberg Change-Id: I0535947e9cd9c6e0cf896e81b127d93cab54ebc8 --- ethosu/vela/tensor_allocation.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ethosu/vela/tensor_allocation.py b/ethosu/vela/tensor_allocation.py index b7057f0b..621073a3 100644 --- a/ethosu/vela/tensor_allocation.py +++ b/ethosu/vela/tensor_allocation.py @@ -67,6 +67,8 @@ def hillclimb_allocate_live_ranges(live_ranges: LiveRangeGraph, alloc_granularit # Allocates using the hill climb allocator lr_set = {(lr.start_time, lr.end_time, lr) for lr in live_ranges.ranges.values()} lr_list = [lr for _, _, lr in lr_set] + lr_list.sort() + addresses = hillclimb_allocation.allocate_live_ranges(lr_list) # The result is a list containing the allocated addresses total_sz = 0 -- cgit v1.2.1