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
Bump VCPU from u8 to u32 #6446
Bump VCPU from u8 to u32 #6446
Conversation
Modified vcpu related information to support more vcpu's. Signed-off-by: Kshitij Kapoor <kshitij@utexas.edu>
Modified vcpu related information to support more vcpu's. Signed-off-by: Kshitij Kapoor <kshitij@utexas.edu>
The new vcpu size is an unsigned int of 32 bits, modified the docs to reflect this Signed-off-by: Kshitij Kapoor <kshitij@utexas.edu>
Modified vcpu related information to support more vcpu's Signed-off-by: Kshitij Kapoor <kshitij@utexas.edu>
Modified vcpu related information to support more vcpu's Signed-off-by: Kshitij Kapoor <kshitij@utexas.edu>
Modified vcpu related information to support more vcpu's, mostly in the vmm package Signed-off-by: Kshitij Kapoor <kshitij@utexas.edu>
@@ -1213,7 +1213,7 @@ impl CpuManager { | |||
|
|||
// This reuses any inactive vCPUs as well as any that were newly created | |||
for vcpu_id in self.present_vcpus()..desired_vcpus { | |||
let vcpu = Arc::clone(&self.vcpus[vcpu_id as usize]); | |||
let vcpu = Arc::clone(&self.vcpus[vcpu_id as u32]); |
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.
This won't work - you can't subscript with u32. Did you run clippy over all the commits? (or better - set up the pre-commit hook from CONTRIBUTING.md to do it for you.)
The old issue implies that it is more complicated than just changing the type. Has the underlying issue been resolved? |
I noticed that Rob did some work before: #5600. Would you like to tell about underlying issue you encountered? @rbradford |
I looked into this at one point when doing some CPU topology work. At least on x86_64, when we go above 254 vCPUs (the current max on x86_64 cloud-hypervisor), we may run into issues related to (io/x2/x)apic configuration. From what I remember:
I don't think that we are that far off of support for >255 cpus on x86_64, but it requires some Intel doc reading to make sure we aren't doing anything evil. |
I think @thomasbarrett covered it well - there is also the issue of the mptable becoming too large and overwriting other in memory structures. Correctly addressing this issue requires cultivating a good understanding of the appropriate x86 quirks - other architectures may be significantly simpler. Either way this is much more complicated than just bumping some data types. I'm going to close this PR because it doesn't even do the data type bump correctly (doesn't compile). |
Bumped related information to u32 data type to support more vcpu's
#5345