-
Notifications
You must be signed in to change notification settings - Fork 270
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Reduce CPU pinning fragmentation #384
Conversation
A bit note: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Usually, I am a bit skeptical about the usefulness of the unit tests but in case of the VmsCpuPinningPolicyComparator
I think it might be actually useful to provide some VMs and see what is the expected output for different pinning, pinning policies and topologies.
...org/ovirt/engine/core/common/businessentities/comparators/VmsCpuPinningPolicyComparator.java
Outdated
Show resolved
Hide resolved
...org/ovirt/engine/core/common/businessentities/comparators/VmsCpuPinningPolicyComparator.java
Outdated
Show resolved
Hide resolved
...anager/modules/bll/src/main/java/org/ovirt/engine/core/bll/scheduling/SchedulingManager.java
Outdated
Show resolved
Hide resolved
yeah, in this case it will also serve as a documentation |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've commented on #380
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I moved all the sort related discussions to this PR.
...anager/modules/bll/src/main/java/org/ovirt/engine/core/bll/scheduling/SchedulingManager.java
Outdated
Show resolved
Hide resolved
...org/ovirt/engine/core/common/businessentities/comparators/VmsCpuPinningPolicyComparator.java
Outdated
Show resolved
Hide resolved
...anager/modules/bll/src/main/java/org/ovirt/engine/core/bll/scheduling/SchedulingManager.java
Outdated
Show resolved
Hide resolved
...org/ovirt/engine/core/common/businessentities/comparators/VmsCpuPinningPolicyComparator.java
Outdated
Show resolved
Hide resolved
...org/ovirt/engine/core/common/businessentities/comparators/VmsCpuPinningPolicyComparator.java
Outdated
Show resolved
Hide resolved
Based on the offline discussion:
|
d937243
to
196bcfe
Compare
Need to verify, and add unit tests. But this is how it looks now. |
a03ea57
to
dbcb0cd
Compare
...org/ovirt/engine/core/common/businessentities/comparators/VmsCpuPinningPolicyComparator.java
Outdated
Show resolved
Hide resolved
...anager/modules/bll/src/main/java/org/ovirt/engine/core/bll/scheduling/SchedulingManager.java
Outdated
Show resolved
Hide resolved
...anager/modules/bll/src/main/java/org/ovirt/engine/core/bll/scheduling/SchedulingManager.java
Outdated
Show resolved
Hide resolved
...org/ovirt/engine/core/common/businessentities/comparators/VmsCpuPinningPolicyComparator.java
Outdated
Show resolved
Hide resolved
1ea8bcd
to
2076b6a
Compare
...les/common/src/main/java/org/ovirt/engine/core/common/businessentities/CpuPinningPolicy.java
Show resolved
Hide resolved
This patch sorts the VM list on schedule phase before doing the dedicated CPU pinning. This change tries to reduce the fragmentation that may be caused when allocating a smaller VM in terms of the policy and CPU topology (a less restricted) when having a bigger one. Scheduling the smaller VM first may cause less physical resources needed by the larger VM because we try to enhance performance in the allocation logic. Now, the VMs will be sorted based on the policy first and if needed by the CPU topology, letting the more restricted VM to be scheduled first. Change-Id: Ia3fc28511c147d43da9cf8d86d50ca17f1e3f0e1 Signed-off-by: Liran Rotenberg <lrotenbe@redhat.com>
2076b6a
to
4cc058f
Compare
/ost |
OST failed on UI test, unrelated to the patch. |
This patch sorts the VM list on schedule phase before doing the
dedicated CPU pinning.
This change tries to reduce the fragmentation that may be caused when
allocating a smaller VM in terms of the policy and CPU topology (a less
restricted) when having a bigger one. Scheduling the smaller VM first
may cause less physical resources needed by the larger VM because we try
to enhance performance in the allocation logic.
Now, the VMs will be sorted based on the policy first and if needed by
the CPU topology, letting the more restricted VM to be scheduled first.
Change-Id: Ia3fc28511c147d43da9cf8d86d50ca17f1e3f0e1
Signed-off-by: Liran Rotenberg lrotenbe@redhat.com