WU UCB CS152/252 SP18
CS152/252 Spring 2018
Computer Architecture and Engineering
Graduate Computer Architecture
Lecture 22:
Virtual Machines
Lisa Wu, Krste Asanovic
http://inst.eecs.berkeley.edu/~cs152/sp18
©"Krste"Asanovic,"2015CS252,"Fall"2015,"Lecture"17
Outline
§ What"are"Virtual"Machines"and"why"do" we"need"
them?"
§ Types"of"Virtual"Machine
- User-level
- System-level
§ Techniques" for" implementing"all"or"parts"of"a"non-
native"ISA"on"a"host"machine:
- Interpreter
- Static"binary"translation
- Dynamic"binary"translation
- Hardware"emulation
2
WU UCB CS152/252 SP18
A Computer System Abstraction
3
WU UCB CS152/252 SP18
What are Virtual Machines (VMs)?
4
“Virtual Machines (VMs) eliminate real machine constraints
and enable a much higher degree of portability and
flexibility.”
“Virtual Machines: Architectures, Implementations and Applications”,
J. E. Smith and Ravi Nair, Morgan Kaufmann Publishers, 2004
“A virtual machine may have an operating system,
instruction set, or both, that differ from those implemented
on the underlying real hardware.”
“A virtual machine is implemented by adding software to an
execution platform to give it the appearance of a different
platform or for that matter, to give the appearance of
multiple platforms.”
©"Krste"Asanovic,"2015CS252,"Fall"2015,"Lecture"17
Types,of,Virtual,Machine,(VM)
§ User/Process,Virtual,Machines,run"a"single"application"
according"to"some"standard"application"binary"interface"
(ABI).
- Example"user"ABIs"include"Win32"for"windows"and"Java"
Virtual"Machine"(JVM)
§ (Operating),System,Virtual,Machines provide"a"
complete" system-level"environment
- E.g.,"IBM"VM/370,"VMware"ESX"Server,"and"Xen
- Single"computer"runs"multiple"VMs,"and"can"support"a"
multiple,"different"OSes
- On"conventional"plat f orm,"single"OS"“owns”"all "H W"resources"
- With"a"VM,"multi ple"OSes all"share"HW"resources
§ Underlying"HW"platform"is"called"the"host,"where"its"
resources"used"to"run"guest"VMs" (user"and/or"system)
5