cmpt454 gpu managed database · gpgpu: general purpose gpu, using gpu for usual cpu usage. outline...

12
CMPT454 GPU Managed Database Wong, Pok Wai(Boris)

Upload: others

Post on 27-Jun-2020

29 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: CMPT454 GPU Managed Database · GPGPU: General Purpose GPU, using GPU for usual CPU usage. Outline 1. GPU VS CPU 2. GPU Implementation 3. Products 4. Future Holds. GPU VS CPU. GPU

CMPT454

GPU Managed Database

Wong, Pok Wai(Boris)

Page 2: CMPT454 GPU Managed Database · GPGPU: General Purpose GPU, using GPU for usual CPU usage. Outline 1. GPU VS CPU 2. GPU Implementation 3. Products 4. Future Holds. GPU VS CPU. GPU

Terminology

GPU: Graphic Processing Unit

CPU: Central Processing Unit

CUDA: NVidia’s GPU process environment

OpenCL: Open compute language

GPGPU: General Purpose GPU, using GPU for usual CPU usage

Page 3: CMPT454 GPU Managed Database · GPGPU: General Purpose GPU, using GPU for usual CPU usage. Outline 1. GPU VS CPU 2. GPU Implementation 3. Products 4. Future Holds. GPU VS CPU. GPU

Outline

1. GPU VS CPU

2. GPU Implementation

3. Products

4. Future Holds

Page 4: CMPT454 GPU Managed Database · GPGPU: General Purpose GPU, using GPU for usual CPU usage. Outline 1. GPU VS CPU 2. GPU Implementation 3. Products 4. Future Holds. GPU VS CPU. GPU

GPU VS CPU

Page 5: CMPT454 GPU Managed Database · GPGPU: General Purpose GPU, using GPU for usual CPU usage. Outline 1. GPU VS CPU 2. GPU Implementation 3. Products 4. Future Holds. GPU VS CPU. GPU

GPU VS CPU

GPU:

1. >1000 CUDA Cores

2. Lower Clock Speed

3. Higher Memory Bandwidth

4. Faster Main Memory(DDR5)

CPU:

1. 2,4,8… Cores

2. Higher Clock Speed For Repetitive Process

3. Consume Less Power

4. Easy to implement

Page 6: CMPT454 GPU Managed Database · GPGPU: General Purpose GPU, using GPU for usual CPU usage. Outline 1. GPU VS CPU 2. GPU Implementation 3. Products 4. Future Holds. GPU VS CPU. GPU

GPU

Pros

Access more records when the algorithm parallelized

Easy to scale up, hardware wise

Efficiency when the algorithm moderate to low flow control

Efficiency for large amount of data set

Page 7: CMPT454 GPU Managed Database · GPGPU: General Purpose GPU, using GPU for usual CPU usage. Outline 1. GPU VS CPU 2. GPU Implementation 3. Products 4. Future Holds. GPU VS CPU. GPU

GPU

Cons

No pre-emptive multi-tasking

Limited memory

Hard to implement

Not good at General Purpose(GPGPU)

Page 8: CMPT454 GPU Managed Database · GPGPU: General Purpose GPU, using GPU for usual CPU usage. Outline 1. GPU VS CPU 2. GPU Implementation 3. Products 4. Future Holds. GPU VS CPU. GPU

GPU Implementation

CUDA:

Benefits

Parallel computing architecture

Unified memory

Faster read back from memory

Support for integer and bitwise operation

Limitation

New C dialect

Only works on NVidia hardware

Page 9: CMPT454 GPU Managed Database · GPGPU: General Purpose GPU, using GPU for usual CPU usage. Outline 1. GPU VS CPU 2. GPU Implementation 3. Products 4. Future Holds. GPU VS CPU. GPU

GPU Implementation

OpenCL

Open standard/source

Access all computer resource

Supported on more than one platform

Efficient parallel programming language

Rich set of built-in function

Hard to implement

GPU parallel computing is not mature in OpenCL

Page 10: CMPT454 GPU Managed Database · GPGPU: General Purpose GPU, using GPU for usual CPU usage. Outline 1. GPU VS CPU 2. GPU Implementation 3. Products 4. Future Holds. GPU VS CPU. GPU

Products

SQream

GPU-accelerated data warehouse for analytics

Uses the GPU to perform database operations

Limited operating data which can fit in GPU RAM

Takes the maximum advantages from GPU

Good implementation with CUDA

Uses Thrust(C++)

High level library for CUDA

Page 11: CMPT454 GPU Managed Database · GPGPU: General Purpose GPU, using GPU for usual CPU usage. Outline 1. GPU VS CPU 2. GPU Implementation 3. Products 4. Future Holds. GPU VS CPU. GPU

Future Holds

Pre-emptive Multi-tasking

Virtual Memory for GPU

Mature Tools(algorithm, language or DBMS)

Hybrid

Tendency: Multi-cores

Page 12: CMPT454 GPU Managed Database · GPGPU: General Purpose GPU, using GPU for usual CPU usage. Outline 1. GPU VS CPU 2. GPU Implementation 3. Products 4. Future Holds. GPU VS CPU. GPU

Referencing

1. Acceleration of data-management using the power of a GPU

https://www.youtube.com/watch?v=Q_WmeJUcTkY

2. Introducing PgOpenCL A New PostgreSQL Procedural Language Unlocking the Power of the GPU! By Tim Child

https://wiki.postgresql.org/images/6/65/Pgopencl.pdf

3. Implementing SQL on GPUs 1/2

https://sqream.com/implementing-sql-on-gpus-part-1/

4. Implementing SQL on GPUs 2/2

https://sqream.com/implementing-sql-on-gpus-part-2/

5. CUDA

https://en.wikipedia.org/wiki/CUDA

6. Thrust

https://thrust.github.io/