Hosted I/O Architecture Micah Dowty Jeremy Sugerman USENIX WIOV - - PowerPoint PPT Presentation

hosted i o architecture
SMART_READER_LITE
LIVE PREVIEW

Hosted I/O Architecture Micah Dowty Jeremy Sugerman USENIX WIOV - - PowerPoint PPT Presentation

GPU Virtualization on VMwares Hosted I/O Architecture Micah Dowty Jeremy Sugerman USENIX WIOV 2008 1 Contents GPUs are hard But GPU virtualization is worth the trouble How to virtualize a GPU? VMwares virtual GPU


slide-1
SLIDE 1

GPU Virtualization on VMware’s Hosted I/O Architecture

Micah Dowty Jeremy Sugerman USENIX WIOV 2008

1

slide-2
SLIDE 2

Contents

  • GPUs are hard
  • But GPU virtualization is worth the trouble
  • How to virtualize a GPU?
  • VMware’s virtual GPU
  • Conclusions
  • In the paper:

– Details on our implementation – Benchmarks, analysis

2

slide-3
SLIDE 3

What is a GPU, anyway?

  • Video playback, 2D graphics, drawing triangles and rectangles and lines...
  • Computation.

3

slide-4
SLIDE 4

How much computation?

Source: AnandTech review of NVidia GT200

Intel Core 2 Duo:

291 million transistors

NVIDIA GeForce GTX 280:

1.4 billion transistors

4

slide-5
SLIDE 5

Programmable 3D Pipeline

Vertex Data Vertex Pipeline

  • Position
  • Material
  • Texture coordinate

Rasterization

  • Plot triangles, lines
  • Interpolate vertices

Pixel Pipeline Framebuffer Texture Data State Pixel Shader State Vertex Shader

(State of the art circa 2002...)

5

slide-6
SLIDE 6

Unique challenges

  • API

– Not quite read(), write(), select()... – Multiple competing APIs – Hundreds of entry points

  • Programmable

– Every GPU driver is also a compiler – Each API includes a language spec

6

slide-7
SLIDE 7

Unique challenges

  • Hardware specs

– Diverse, changes frequently – Closely guarded secret* – Speed vs. portability

  • Hardware state

– Up to gigabytes of data – Highly device-specific format – In-progress DMA and computation

GPU App GPU Driver App App App OpenGL Direct3D Compute

7

* With a few notable exceptions.

slide-8
SLIDE 8

What are GPUs good for?

  • Desktop Apps

– Entertainment – CAD – Multimedia – Productivity

  • Desktop GUIs

– Quartz Extreme – Vista Aero – Compiz

8

slide-9
SLIDE 9

GPUs in the Data Center

  • Server-hosted Desktops
  • GPGPU

9

slide-10
SLIDE 10

API Remoting

GPU GPU Driver OpenGL / Direct3D Hardware Kernel

Host Guest

API User-level RPC Endpoint App App App API OpenGL / Direct3D Redirector

slide-11
SLIDE 11

Device Emulation

GPU GPU Driver OpenGL / Direct3D Hardware Kernel

Host Guest

API User-level Rendering Backend Virtual GPU Virtual GPU Driver App App App Virtual HW Kernel API OpenGL / Direct3D Shader / State Translator Resource Management GPU Emulator Shared System Memory

slide-12
SLIDE 12

Virtual Machine

Fixed pass-through

OpenGL / Direct3D / Compute App GPU Driver App App API Pass-through GPU Physical GPU

PCI IRQ MMIO

VT-d

DMA

slide-13
SLIDE 13

Mediated pass-through

Physical GPU GPU Resource Manager Virtual Machine OpenGL / Direct3D / Compute App GPU Driver App App API Emulation Pass-through GPU Virtual Machine OpenGL / Direct3D / Compute App GPU Driver App App API Emulation Pass-through GPU

slide-14
SLIDE 14

GPU Virtualization Taxonomy

Front-end Back-end Fixed Pass-through 1:1 Mediated Pass-through 1:N Hybrid (Driver VM) API Remoting Device Emulation

14

slide-15
SLIDE 15

VMware’s Virtual GPU

  • Compatibility

– Any physical GPU – Any guest driver stack – Adjustable capability exposure – No direct access to GPU memory

  • Efficiency

– Flexible guest memory management – Few copies – Asynchronous rendering

15

GPU GPU Driver OpenGL / Direct3D Rendering Backend VMware SVGA II Virtual GPU Driver App App App OpenGL / Direct3D Shader / State Translator Resource Management Device Emulation

slide-16
SLIDE 16

VMware SVGA II

16

slide-17
SLIDE 17

Virtual Graphics Stack

GPU GPU API / Driver

Host Guest

SVGA FIFO / Registers VMware SVGA Driver DMA Engine MKS / HostOps Dispatch SVGA Device Guest Mem Shader Program Translator Guest VRAM SVGA GMR App

3D Rendering

Surface Abstraction State Translator 3D Drawing Path

2D Compositing

2D 3D Video

17

slide-18
SLIDE 18

Evaluation

  • Applications
  • Microbenchmarks
  • VMware Fusion 2.0,

VMware Workstation 6.5, Parallels Desktop 3.0, SwiftShader

  • Mac Pro, 8-core 2.8 GHz
  • ATI Radeon HD2600

18

slide-19
SLIDE 19

Application Benchmarks

19

slide-20
SLIDE 20

Summary

  • GPU Virtualization is an important problem
  • Room for improvement in implementation

completeness and performance...

  • But we can already run interactive apps that

could never be virtualized before

  • Virtual GPU preserves portability + isolation

20

slide-21
SLIDE 21

Future Work

  • Pass-through techniques

– Fixed and Mediated – Can be complementary to Virtual GPU

  • Continued improvements

– Performance and functionality – At all layers of driver stack

  • Virtualization-aware GPU benchmarks

21

slide-22
SLIDE 22

Questions?

  • micah@vmware.com

22