Thanks to visit codestin.com
Credit goes to github.com

Skip to content
This repository was archived by the owner on Feb 24, 2020. It is now read-only.

Conversation

@squall0gd
Copy link
Contributor

When lkvm is using more vcpus than platform has got, then VMs
spinning up is very slow. This patch blocks this behavior and
when user choose more vcpus then platform has cores, then
number of cpus is set to number of cores

// In case when number of specified cpus is greater than
// number or when cpus aren't specified, we set number
// of logical cpus as a limit.
available_cpus := int64(runtime.NumCPU())
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do we need operate on int64 if in findResources bytes are converted to megabytes ?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

prefer camelcase - availableCpus

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jonboulle, @woodbor sure

@squall0gd squall0gd force-pushed the mstachow/rkt_kvm_performance_improvement branch from b07fc88 to 708ab5d Compare March 24, 2016 15:28
When lkvm is using more vcpus than platform has got, then VMs
spinning up is very slow. This patch blocks this behavior and
when user choose more vcpus then platform has cores, then
number of cpus is set to number of cores
@squall0gd squall0gd force-pushed the mstachow/rkt_kvm_performance_improvement branch from 708ab5d to dead82a Compare March 25, 2016 09:02
@squall0gd
Copy link
Contributor Author

Review request

@jellonek
Copy link
Contributor

LGTM

@jonboulle jonboulle added this to the v1.3.0 milestone Mar 25, 2016
@jonboulle jonboulle merged commit 5716729 into rkt:master Mar 25, 2016
@squall0gd squall0gd deleted the mstachow/rkt_kvm_performance_improvement branch April 11, 2016 08:38
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants