This patch provides some small updates to enable catching and
handling when memory runs out (std::bad_alloc). Specifically,
when this happens, we can no longer use std::cout which
does many allocations in the process. Instead we exit
gracefully with an error code.
Signed-off-by: “Rian <“rianquinn@gmail.com”>
This patch provides support for the google sanatizers for
dynamic analysis, as well as cleans up issues with clang tidy.
In addition, there is a new Travis CI target that tests for
clang tidy so that future PRs do not have the same issues.
Signed-off-by: “Rian <“rianquinn@gmail.com”>
The previous VCPU implementation was put in place for 1.0
because we didn't have support for "gs" based state save
area. Now that we have that, we no longer need to call the
vcpu manager on every VM exit.
In addition, for version 1.2, we will need the ability to
create vcpuids that are no longer linear, and thus, an
array and hard coded MAX will not work. This patch removes
these limitations, and provides a means to have as many
vCPUs as needed in the future.
Signed-off-by: “Rian <“rianquinn@gmail.com”>
Originally, the error codes were self contained which made sense
at the time, but as the project has grown, the number of error
codes has increased leading to a lot of redudancy in common.c as
well as overlapping error codes in a couple of cases. This patch
moves all of the error codes toa single file, makes sure the
return types are consistent, and provides a single error code
to string conversion function
Signed-off-by: “Rian <“rianquinn@gmail.com”>
Updated the compiler flags to enable better arch support for
Intel. Also added FXSAVE and FXRSTOR instructions to ensure
the entire reigster state is being saved. If we ever use
AVX, we will need to use XSAVE instead
Signed-off-by: “Rian <“rianquinn@gmail.com”>