Show understanding of the concept of a virtual machine (VM) and its role in modern computing, including its types, architecture, benefits, limitations, security issues and relevance to parallel processing and cloud‑computing.
A virtual machine (VM) is a software abstraction that emulates a complete physical computer system. It provides an isolated execution environment that behaves like a real processor, memory, storage and I/O devices, allowing programmes to run as if they were on dedicated hardware.
RISC (Reduced Instruction Set Computing) processors use a small, highly optimised set of instructions that can execute in a single clock cycle. CISC (Complex Instruction Set Computing) processors provide many more instructions, some of which perform complex operations in a single instruction.
Both families employ pipelining – the technique of overlapping the fetch, decode, execute and write‑back stages of several instructions so that multiple instructions are in different stages of execution at the same time. Pipelining increases instruction throughput but introduces hazards that the hardware must resolve.
Because a VM abstracts the underlying ISA, the same guest OS or process VM can run on a RISC‑based host (e.g., ARM) or a CISC‑based host (e.g., x86) without modification. The hypervisor translates privileged VM instructions into the appropriate native ISA, shielding the guest from hardware differences.
| Architecture | Definition | Typical Use | VM Relevance |
|---|---|---|---|
| SISD | Single Instruction, Single Data stream – a single processor executes one instruction on one datum at a time. | Traditional desktop CPUs. | A single‑CPU VM maps one vCPU to the physical core; no inherent parallelism. |
| SIMD | Single Instruction, Multiple Data – one instruction operates on many data elements simultaneously. | Vector processors, GPU shaders. | A VM can expose SIMD extensions (e.g., AVX) to guests, allowing parallel data processing inside the VM. |
| MISD | Multiple Instruction, Single Data – rare in practice; multiple processors work on the same datum. | Specialised fault‑tolerant systems. | Not commonly virtualised; would require coordinated scheduling of several vCPUs on the same data stream. |
| MIMD | Multiple Instruction, Multiple Data – independent processors execute different instructions on different data. | Multi‑core and distributed systems. | System VMs on a MIMD host allocate separate vCPUs to each guest, enabling true parallel execution of several OSes or applications. |
Massively‑parallel systems contain dozens, hundreds or thousands of processing elements (cores, GPU streaming processors, or specialised accelerator tiles) that work concurrently on large data sets. Examples include modern GPU arrays, many‑core CPUs (e.g., Intel Xeon Phi) and dedicated super‑computers.
When a host is massively parallel, the hypervisor can provision a VM with many vCPUs, allowing the guest to exploit the underlying parallel hardware. In practice, the guest OS schedules its own threads across the allocated vCPUs, which the hypervisor maps onto the physical cores.
The host computer runs a hypervisor (also called a virtual‑machine monitor). The hypervisor sits between the physical hardware and the VMs and performs two essential tasks:
| Benefit | Explanation |
|---|---|
| Consolidation | Many VMs replace multiple physical servers, reducing hardware purchase and energy costs. |
| Testing & Development | Developers can create disposable environments, test software on different OSes, and revert to a clean snapshot instantly. |
| Security Isolation | A compromised VM can be shut down or deleted without affecting the host or other VMs. |
| Scalability & Flexibility | Resources (CPU, RAM, storage) can be re‑allocated to VMs on demand, supporting dynamic workloads. |
Modern cloud services (IaaS – Infrastructure as a Service) rely heavily on VMs. Providers such as Amazon EC2, Microsoft Azure and Google Compute Engine offer virtual machines that can be created, resized and destroyed on demand, illustrating the concepts of portability, scalability and consolidation covered in this unit.
On a multi‑core or massively‑parallel host, the hypervisor can schedule different VMs on different physical cores, achieving true parallel execution. A single VM may also be configured with multiple vCPUs, which the hypervisor maps onto available cores.
The theoretical speed‑up when a portion of a programme is parallelised is given by:
$$S = \frac{1}{(1 - P) + \frac{P}{N}}$$
where:
Example: If 80 % of a workload can be parallelised (P = 0.8) and the VM is given 4 vCPUs (N = 4), the expected speed‑up is:
$$S = \frac{1}{(1-0.8) + \frac{0.8}{4}} = \frac{1}{0.2 + 0.2} = 2.5$$
This demonstrates diminishing returns as the non‑parallel portion dominates, a point that is examined in the AO2 parallel‑processing criteria.
The JVM is a process virtual machine that executes Java bytecode. Key features include:
.class files run on any device with a compatible JVM.Create an account or Login to take a Quiz
Log in to suggest improvements to this note.
Your generous donation helps us continue providing free Cambridge IGCSE & A-Level resources, past papers, syllabus notes, revision questions, and high-quality online tutoring to students across Kenya.