Skip to content

Commit

Permalink
fix uunifast-discard generator to handle tasksets of only 1 task
Browse files Browse the repository at this point in the history
  • Loading branch information
Maxime Chéramy committed Oct 28, 2018
1 parent 8e1cd1f commit 6051718
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions simso/generator/task_generator.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,10 @@ def UUniFastDiscard(n, u, nsets):
nextSumU = sumU * random.random() ** (1.0 / (n - i))
utilizations.append(sumU - nextSumU)
sumU = nextSumU
utilizations.append(nextSumU)
utilizations.append(sumU)

# If no task utilization exceeds 1:
if not [ut for ut in utilizations if ut > 1]:
if all(ut <= 1 for ut in utilizations):
sets.append(utilizations)

return sets
Expand Down

0 comments on commit 6051718

Please sign in to comment.