Home > Back-end >  Is there a way to check if virtualisation is enabled on the BIOS using C ?
Is there a way to check if virtualisation is enabled on the BIOS using C ?

Time:08-05

I'm trying to check if virtualisation (AMD-V or Intel VT) is enabled programmatically. I know the bash commands that gives you this information but I'm trying to achieve this in C .

On that note, I'm trying to avoid using std::system to execute shell code because of how hacky and unoptimal that solution is. Thanks in advance!

CodePudding user response:

No, there is no way to detect virtualization support using only standard C facilities. The C standard library does not have anything related to hardware virtualization. (Its exposure of low level details like that is extremely limited.)

You would need to use OS-specific facilities to detect this.

  • Related