Title Heterogeno programiranje u jeziku C++
Title (english) Heterogeneous programming in C++
Author Matej Crnković
Mentor Mladen Jurak (mentor)
Committee member Mladen Jurak (predsjednik povjerenstva)
Committee member Zvonimir Bujanović (član povjerenstva)
Committee member Zlatko Drmač (član povjerenstva)
Committee member Marko Erceg (član povjerenstva)
Granter University of Zagreb Faculty of Science (Department of Mathematics) Zagreb
Defense date and country 2024-11-28, Croatia
Scientific / art field, discipline and subdiscipline NATURAL SCIENCES Mathematics
Abstract U doba rastućih potreba za sustavima visokih performansi nužno je razvijati alate koji će biti u korak s vremenom i pratiti razvoj tehnologije. Heterogeno programiranje u kombinaciji s C++ jezikom donosi ključan korak prema učinkovitoj upotrebi računalnih resursa u tehničkim i znanstvenim područjima poput paralelnog računanja, računalnih simulacija te razvoja modela umjetne inteligencije.
U ovom radu prikazani su temelji heterogenih sustava i heterogenog programiranja, zajedno s detaljnim pregledom SYCL standarda i njegove implementacije kroz oneAPI DPC++ kompajler. Objašnjen je postupak postavljanja lokalne SYCL okoline te mogucnosti korištenja gotovih okolina u oblaku. Prezentirani su osnovni primjeri koji ilustriraju temeljne SYCL koncepte i klase, kao i metode mjerenja vremena izvršavanja SYCL jezgri. Konvolucijom matrica pokazano je kako povezati C++ višedretvenosti i izvršavanje SYCL programa na nekoliko akceleratora. Uvođenjem ND-Ranges paradigme objašnjena je razlika globalne i lokalne memorije na uređaju kao i načini sinkronizacije radnih stavki unutar iste podgrupe. Na kraju rada opisana je oneAPI DPC++ biblioteka koja omogućuje jednostavnije pisanje heterogenih programa kroz viši nivo apstrakcije i integrirane paralelne mehanizme.
SYCL-ova prenosivost koda i mogućnost unificiranog pristupa različitim akceleratorima značajno pojednostavljuju razvoj heterogenih aplikacija, no zahtijevaju pažljivo razumijevanje hardverske arhitekture za postizanje optimalnih rezultata. Iako su izazovi, poput otežanog postavljanja okoline i prilagodbe specifičnom hardveru, i dalje prisutni, SYCL predstavlja snažan alat za razvoj budućih heterogenih sustava. Uz kontinuirani razvoj SYCL standarda i kompajlera koji ga implementiraju, njegova će prisutnost zasigurno rasti, ponajviše zbog smanjene kompleksnosti u odnosu na druge slične standarde te zbog podrške akceleratore raznih proizvođača.
Abstract (english) In an era of growing demand for high-performance systems, it is essential to develop tools that keep pace with technological advancements. Heterogeneous programming, combined with the C++ language, represents a crucial step towards the efficient use of computational resources in technical and scientific fields such as parallel computing, computational simulations, and the development of artificial intelligence models. This paper presents the fundamentals of heterogeneous systems and heterogeneous programming, along with a detailed review of the SYCL standard and its implementation through the oneAPI DPC++ compiler. The process of setting up a local SYCL environment is explained, as well as the possibilities of using ready-made cloud environments. Basic examples are provided to illustrate fundamental SYCL concepts and classes, as well as methods for measuring the execution time of SYCL kernels. Matrix convolution demonstrates how to link C++ multithreading and the execution of SYCL programs on multiple accelerators. The introduction of the ND-Ranges paradigm explains the difference between global and local memory on the device, as well as synchronization methods for work items within the same subgroup. Finally, the oneAPI DPC++ library is described, which facilitates writing heterogeneous programs through a higher level of abstraction and integrated parallel mechanisms. SYCL's code portability and the ability to provide a unified approach to various accelerators significantly simplify the development of heterogeneous applications, but they require a careful understanding of hardware architecture to achieve optimal results. While challenges, such as the complexity of setting up environments and adapting to specific hardware, remain, SYCL represents a powerful tool for developing future heterogeneous systems. With the continuous development of the SYCL standard and the compilers that implement it, its presence will undoubtedly grow, primarily due to reduced complexity compared to other similar standards and its support for accelerators from various manufacturers.
Keywords
jezik C++
SYCL
heterogeno programiranje
računalstvo visokih performansi
Keywords (english)
C++ language
SYCL
heterogeneous computing
high-performance computing
Language croatian
URN:NBN urn:nbn:hr:217:369038
Study programme Title: Computer Science and Mathematics Study programme type: university Study level: graduate Academic / professional title: sveučilišni magistar računarstva i matematike (sveučilišni magistar računarstva i matematike)
Type of resource Text
File origin Born digital
Access conditions Open access
Terms of use
Created on 2024-11-12 14:46:49