izpis_h1_title_alt

Prevajanje funkcijskega programskega jezika v WebAssembly
ID Ocvirk, Krištof (Author), ID Pretnar, Matija (Mentor) More about this mentor... This link opens in a new window

.pdfPDF - Presentation file, Download (204,85 KB)
MD5: 5F9A426A758ABDC7D267FC6CB96D7EC2

Abstract
WebAssembly je z dodatkom objektov na kopici postal še bolj privlačen programski jezik, saj lahko vanj brez dodatnega truda prevajamo tudi jezike, ki uporabljajo smetarja. V okviru tega diplomskega dela smo se odločili prevesti funkcijski jezik Millet v WebAssembly. V tem delu najprej predstavimo oba jezika in nato opišemo, kako je bil Millet preveden v WebAssembly. Prevod je direkten, in sicer vsakemu ukazu določimo, v katere WebAssembly ukaze se bo prevedel, poleg tega moramo določiti še nekaj tipov, potrebnih za pravilno izvajanje ter validacijo prevedene kode. Prevedena koda se izvaja pravilno in v vsakem primeru prehiti Milletovo izvorno kodo za vsaj dvestokrat. Ker koda ni optimizirana, še vedno potrebuje nekaj izboljšav, da bo njeno delovanje bolj primerljivo s programi napisanimi v WebAssembly-ju.

Language:Slovenian
Keywords:prevajalniki, WebAssembly, funkcijski programski jeziki
Work type:Bachelor thesis/paper
Typology:2.11 - Undergraduate Thesis
Organization:FRI - Faculty of Computer and Information Science
Year:2024
PID:20.500.12556/RUL-162807 This link opens in a new window
COBISS.SI-ID:214439939 This link opens in a new window
Publication date in RUL:27.09.2024
Views:109
Downloads:24
Metadata:XML DC-XML DC-RDF
:
Copy citation
Share:Bookmark and Share

Secondary language

Language:English
Title:Compilation of a functional programming language to WebAssembly
Abstract:
WebAssembly has become an even more attractive target programming language with the addition of heap objects, allowing many languages to be compiled into WebAssembly without the additional effort of translating their garbage collectors as well. In this thesis, we decided to compile the functional language Millet into WebAssembly. In this work, we first introduce both languages and then describe how Millet was compiled into WebAssembly. The translation is direct, meaning that each Millet instruction is mapped it to the corresponding WebAssembly instructions. We also had to specify the appropriate types for correct execution and validation of the compiled code. The translated code runs correctly and outperforms Millet’s original code by at least two hundred times in every case. Since the code is not yet optimized, it still requires a few improvements to perform more comparably to programs written directly in WebAssembly.

Keywords:compilers, WebAssembly, functional programming languages

Similar documents

Similar works from RUL:
Similar works from other Slovenian collections:

Back