many-sc programming model jaejin lee center for manycore programming seoul national university...
TRANSCRIPT
![Page 1: Many-SC Programming Model Jaejin Lee Center for Manycore Programming Seoul National University 2014.06.27 1 2014-06-27](https://reader035.vdocument.in/reader035/viewer/2022072013/56649e495503460f94b3cf07/html5/thumbnails/1.jpg)
12014-06-27
Many-SC Programming Model
Jaejin Lee
Center for Manycore Programming
Seoul National University
2014.06.27
![Page 2: Many-SC Programming Model Jaejin Lee Center for Manycore Programming Seoul National University 2014.06.27 1 2014-06-27](https://reader035.vdocument.in/reader035/viewer/2022072013/56649e495503460f94b3cf07/html5/thumbnails/2.jpg)
2014-06-27 2
Schedule for the first yearSchedule (13/11/11~14/11/10)
1 2 3 4 5 6 7 8 9 10 11 12
1 Developing a low-level communication library
2 Developing a threading library
3 Developing a software SVM
4Verification and performance analysis of the low-level communication library and the software SVM on Chundoong
Interim report
Final report
6/27
![Page 3: Many-SC Programming Model Jaejin Lee Center for Manycore Programming Seoul National University 2014.06.27 1 2014-06-27](https://reader035.vdocument.in/reader035/viewer/2022072013/56649e495503460f94b3cf07/html5/thumbnails/3.jpg)
2014-06-27 3
Cluster
The Structure of the Many-SC
Core Core
Core Core
Cluster
Core Core
Core Core
Cluster
Core Core
Core Core
Cluster
Core Core
Core Core
![Page 4: Many-SC Programming Model Jaejin Lee Center for Manycore Programming Seoul National University 2014.06.27 1 2014-06-27](https://reader035.vdocument.in/reader035/viewer/2022072013/56649e495503460f94b3cf07/html5/thumbnails/4.jpg)
2014-06-27 4
The Structure of Typical Cluster Systems
Node
Core Core
Core Core
Node
Core Core
Core Core
Node
Core Core
Core Core
Node
Core Core
Core Core
Interconnection network
![Page 5: Many-SC Programming Model Jaejin Lee Center for Manycore Programming Seoul National University 2014.06.27 1 2014-06-27](https://reader035.vdocument.in/reader035/viewer/2022072013/56649e495503460f94b3cf07/html5/thumbnails/5.jpg)
2014-06-27 5
Developing a Low-level Communication Library
• Many-SC• Cache coherence protocol
• Works between cores in a cluster
• Does not work between cores in different clusters
• It is very similar to the typical cluster systems
• Plan• Developing a low-level communication library for typical cluster systems
• Apply this to the Many-SC
![Page 6: Many-SC Programming Model Jaejin Lee Center for Manycore Programming Seoul National University 2014.06.27 1 2014-06-27](https://reader035.vdocument.in/reader035/viewer/2022072013/56649e495503460f94b3cf07/html5/thumbnails/6.jpg)
2014-06-27 6
Low-level Communication Library
• Provide high-level APIs similar to MPI• The API functions are optimized for SnuCL
• Use RDMA internally
• Some API functions
![Page 7: Many-SC Programming Model Jaejin Lee Center for Manycore Programming Seoul National University 2014.06.27 1 2014-06-27](https://reader035.vdocument.in/reader035/viewer/2022072013/56649e495503460f94b3cf07/html5/thumbnails/7.jpg)
2014-06-27 7
SnuCL
• An OpenCL framework for heterogeneous clusters• Platform layer + runtime + kernel compiler
• Freely available, open-source software • Supports OpenCL 1.2
• Passed most of OpenCL conformance tests
• Supports x86 CPUs, ARM CPUs, AMD GPUs, NVIDIA GPUs, Intel Xeon Phi coprocessors (from July, 2013)
• With SnuCL, an OpenCL application written for a single operating system instance runs on a heterogeneous cluster without any modi-fication
![Page 8: Many-SC Programming Model Jaejin Lee Center for Manycore Programming Seoul National University 2014.06.27 1 2014-06-27](https://reader035.vdocument.in/reader035/viewer/2022072013/56649e495503460f94b3cf07/html5/thumbnails/8.jpg)
2014-06-27 8
The Structure of SnuCL
![Page 9: Many-SC Programming Model Jaejin Lee Center for Manycore Programming Seoul National University 2014.06.27 1 2014-06-27](https://reader035.vdocument.in/reader035/viewer/2022072013/56649e495503460f94b3cf07/html5/thumbnails/9.jpg)
2014-06-27 9
Replacing Communication Library
Hardware
MPI
SnuCL
OpenCL Applications
Hardware
Low-level commu-nication library
SnuCL
OpenCL Applications
![Page 10: Many-SC Programming Model Jaejin Lee Center for Manycore Programming Seoul National University 2014.06.27 1 2014-06-27](https://reader035.vdocument.in/reader035/viewer/2022072013/56649e495503460f94b3cf07/html5/thumbnails/10.jpg)
2014-06-27 10
Performance
4KB 8KB 16KB 32KB 64KB 128KB 256KB 512KB 1MB90%
95%
100%
105%
110%
115%
120%
SnuCL+MPI SnuCL+Low-level
Sp
ee
du
p
![Page 11: Many-SC Programming Model Jaejin Lee Center for Manycore Programming Seoul National University 2014.06.27 1 2014-06-27](https://reader035.vdocument.in/reader035/viewer/2022072013/56649e495503460f94b3cf07/html5/thumbnails/11.jpg)
2014-06-27 11
Developing Thread Library
• Provide a subset of POSIX thread API functionsName Description
int pthread_create(pthread_t *thread,const pthread_attr_t *attr, void *(*start_routine)(void *),
void *arg);
Starts a new thread in the calling process
void pthread_exit(void *status); Terminate calling thread
int pthread_join(pthread_t thread, void **status); Join with terminated thread
pthread_t pthread_self(void); Obtain ID of the calling thread
int pthread_mutex_init(pthread_mutex_t *mutex,const pthread_mutexattr_t *attr);
Initialize a mutex
int pthread_mutex_destroy(pthread_mutex_t *mutex);
Destroy a mutex
int pthread_mutex_lock(pthread_mutex_t *mutex); Lock a mutexint pthread_mutex_unlock(pthread_mutex_t *mu-tex); Unlock a mutex
int pthread_barrier_init(pthread_barrier_t *restrict barrier,const pthread_barrierattr_t *restrict attr, unsigned count);
Initialize a barrier
int pthread_barrier_destroy(pthread_barrier_t *bar-rier); Destroy a barrier
int pthread_barrier_wait(pthread_barrier_t *barrier); Synchronize at a barrier
![Page 12: Many-SC Programming Model Jaejin Lee Center for Manycore Programming Seoul National University 2014.06.27 1 2014-06-27](https://reader035.vdocument.in/reader035/viewer/2022072013/56649e495503460f94b3cf07/html5/thumbnails/12.jpg)
2014-06-27 12
Current Status and Future Plan
• Developing a low-level communication library• Done for cluster systems
• Need to be applied to the Many-SC
• Developing a threading library• Defining API functions is done
• Developing a software SVM for cluster systems• Need to implement
• Verification and performance analysis on Chundoong
![Page 13: Many-SC Programming Model Jaejin Lee Center for Manycore Programming Seoul National University 2014.06.27 1 2014-06-27](https://reader035.vdocument.in/reader035/viewer/2022072013/56649e495503460f94b3cf07/html5/thumbnails/13.jpg)
132014-06-27
The End