Trillium: The Code is the IR
Amogh Akshintala, Hangchen Yu, Arthur M. Peters, Christopher J. Rossbach
Trillium: The Code is the IR Amogh Akshintala, Hangchen Yu , Arthur - - PowerPoint PPT Presentation
Trillium: The Code is the IR Amogh Akshintala, Hangchen Yu , Arthur M. Peters, Christopher J. Rossbach Brief Overview GPGPU Virtualization End-to-end comparison of prior approaches Lessons learnt: Virtual ISA unnecessary
Amogh Akshintala, Hangchen Yu, Arthur M. Peters, Christopher J. Rossbach
#2
GPGPU Virtualization End-to-end comparison of prior approaches Lessons learnt:
#3
GPU CPU
Performance Gain
Scientific Computing Machine Learning
#4
Performance Cost
P3.2xlarge 1x V100, $2,200/mo P2.xlarge 1x K80, $650/mo g3s.xlarge 1x M60, $540/mo
Credits to BitFusion Inc.
#5
Performance Cost
P3.2xlarge 1x V100, $2,200/mo P2.xlarge 1x K80, $650/mo g3s.xlarge 1x M60, $540/mo Virtual V100 0.75x V100, $1,500 Virtual V100 0.5x V100, $1,000
Credits to BitFusion Inc.
#6
Sharing Interposition Isolation Compatibility Slowdown Pass Through ❌ 1x Full-virtualization
Everybody sacrifices something
User-mode API Remoting Para-virtualization
#8
Hypervisor Virtual GPU
Native stack
Vendor Library Vendor Driver GPU VM Application Vendor Library Vendor Driver
Sharing Interposition Isolation Compatibility Slowdown
✔︐ ✔︐ ✔︐ ❌ 100x
#11
User-mode API Remoting
Native stack
Hypervisor Custom API Server Vendor Library Vendor Driver GPU VM Application Custom User-mode Library
Sharing Interposition Isolation Compatibility Slowdown
✔︐ ❌ ✔︐/❌ ❌ 1.5x
#13
Native stack
Hypervisor Vendor Library Vendor Driver GPU VM Application Custom User-mode Library Interface Translator Custom Guest Driver Custom Virtual GPU
Sharing Interposition Isolation Compatibility Slowdown
✔︐ ✔︐ ✔︐ ❌ 10x
#18
#19
#20
Sharing Interposition Isolation Compatibility Slowdown Full-virtualization ✔︐ ✔︐ ✔︐ ❌ 100x User-mode API Remoting ✔︐ ❌ ✔︐/❌ ❌ 1.5x Para-virtualization ✔︐ ✔︐ ✔︐ ❌ 10x
#22
Sharing Interposition Isolation Compatibility Slowdown Full-virtualization ✔︐ ✔︐ ✔︐ ❌ 100x User-mode API Remoting ✔︐ ❌ ✔︐/❌ ❌ 1.5x Para-virtualization ✔︐ ✔︐ ✔︐ ❌ 10x Para-virtual API remoting ✔︐ ✔︐ ✔︐ 1.5x
#26
Native stack
Hypervisor Vendor Library Vendor Driver GPU VM Application Translator
OpenGL/DX11 Libraries
vmwgfx.ko SVGA Device
TGSI, Tungsten Graphics Shader Infrastructure, is an intermediate language for describing shaders.
GLSL Code TGSI Native ISA
#31
Native stack
Hypervisor Vendor Library GPU VM Application
Mesa3D OpenCL Library
Nouveau OpenCL Code TGSI Native ISA TGSI LLVM Compiler Nouveau TGSI Xen-SVGA Device
#32
Native stack
Hypervisor Vendor Library GPU VM Application
Mesa3D OpenCL Library
Nouveau OpenCL Code TGSI Native ISA TGSI LLVM Compiler Nouveau TGSI Xen-SVGA Device
#33
PTX, a low-level parallel thread execution virtual machine and instruction set architecture (ISA).
#37
Native stack
Hypervisor Vendor Library Nouveau GPU VM Application
Mesa3D OpenCL Library
Nouveau OpenCL Code Native ISA Trillium Device
#39
#40
✓ Virtual ISA is unnecessary ✓ Para-virtual API remoting system performs better Sharing Interposition Isolation Compatibility Slowdown User-mode API Remoting ✔︐ ❌ ✔︐/❌ ❌ 1.5x Para-virtualization ✔︐ ✔︐ ✔︐ ❌ 10x Trillium ✔︐ ✔︐ ✔︐ ❌ 2.4x
#41
Sharing Interposition Isolation Compatibility Slowdown User-mode API Remoting ✔︐ ❌ ✔︐/❌ ❌ 1.5x Para-virtualization ✔︐ ✔︐ ✔︐ ❌ 1-10x Trillium ✔︐ ✔︐ ✔︐ ❌ 2.4x ✕ Interposing too low in the stack ✕ API-specific
#42
Sharing Interposition Isolation Compatibility Slowdown User-mode API Remoting ✔︐ ❌ ✔︐/❌ ❌ 1.5x Para-virtualization ✔︐ ✔︐ ✔︐ ❌ 1-10x Trillium ✔︐ ✔︐ ✔︐ ❌ 2.4x AvA ✔︐ ✔︐ ✔︐ ✔︐ <1.5x ✕ Interposing too low in the stack ✕ API-specific
#45
Para-virtual API Stack
Native stack
CL.h + Annotations
Hypervisor Generated API Server Vendor Library Vendor Driver Accelerators VM Application AvA Guest Driver AvA Virtual Device
Generated User-mode Library
#46
Preliminary development effort
Type APIs LoC Time Difficulty GPUvm Full-virt 1 20 000 Years ★★★★ SVGA2 Para-virt 2 MANY! Years ★★★★ AvA Automatic Para-virtual API Remoting 9 OpenCL: 835 Days ★
#47
Lessons
○ Decouple device virtualization from GPU ISA virtualization
New para-virtual API remoting system: AvA