qmemman: do not trim the mem-set value too much

We used to mem-set the domain to 0.995*calculated_value; 5 promils of 4GB
is ca 19MB, and it is too visible. Use 0.999 instead of 0.995
This commit is contained in:
Rafal Wojtczuk 2010-09-16 16:40:09 +02:00
parent eea01fba3b
commit c411519220

View File

@ -97,7 +97,7 @@ def balance_when_enough_memory(domdict, xenfree, total_mem_pref, totalsum):
scale = 1.0*prefmem(domdict[i])/total_mem_pref
target_nonint = prefmem(domdict[i]) + scale*totalsum
#prevent rounding errors
target = int(0.995*target_nonint)
target = int(0.999*target_nonint)
if (target < domdict[i].memory_actual):
donors_rq.append((i, target))
else: