izpis_h1_title_alt

Lastništvo objektov namesto avtomatskega čistilca pomnilnika med lenim izračunom
ID Bizjak, Niki (Author), ID Slivnik, Boštjan (Mentor) More about this mentor... This link opens in a new window

.pdfPDF - Presentation file, Download (760,94 KB)
MD5: 0C58DBBB2694A7D42DE3C4C43CB656B8

Abstract
Pomnilnik je kljub uvedbi pomnilniške hierarhije še vedno najpočasnejši del računalniške arhitekture, zato je upravljanje z njim ključnega pomena pri hitrosti izvajanja programov. V zadnjih letih se predvsem na področju sistemskega programiranja vedno bolj uveljavlja programski jezik Rust, ki za čiščenje pomnilnika uporablja princip lastništva in izposoje, s katerima zna med prevajanjem zagotoviti predvidljivo in učinkovito sproščanje pomnilnika. V obsegu magistrskega dela nas zanima, ali je mogoče princip lastništva implementirati v len funkcijski programski jezik STG, ki se uporablja pri prevajanju jezika Haskell. V magistrskem delu implementiramo simulator STG stroja, v katerega dodamo analizo lastništva. Pri tem se izkaže, da s tem zelo omejimo delovanje jezika, saj onemogočimo deljenje objektov. Predstavimo dve rešitvi: globoko kloniranje objektov, za katerega se izkaže, da je zelo časovno in prostorsko potratno, in model lastništva, ki zahteva analizo premikov in izposoj. A izkaže se, da analize izposoj ni mogoče implementirati brez uvedbe bodisi dodatnih informacij o izračunanosti objektov bodisi neke oblike neučakanosti v len programski jezik.

Language:Slovenian
Keywords:prevajalnik, nestroga semantika, len izračun, upravljanje s pomnilnikom, avtomatični čistilec pomnilnika, lastništvo objektov
Work type:Master's thesis/paper
Typology:2.09 - Master's Thesis
Organization:FRI - Faculty of Computer and Information Science
Year:2024
PID:20.500.12556/RUL-162493 This link opens in a new window
COBISS.SI-ID:210384387 This link opens in a new window
Publication date in RUL:24.09.2024
Views:139
Downloads:36
Metadata:XML DC-XML DC-RDF
:
Copy citation
Share:Bookmark and Share

Secondary language

Language:English
Title:Ownership model instead of garbage collection during lazy evaluation
Abstract:
Despite the introduction of memory hierarchy, memory still remains the slowest part of computer architecture, making its management crucial for program execution speed. In recent years, the Rust programming language has been gaining prominence, particularly in the field of systems programming, due to its use of ownership and borrowing models in memory management. This master thesis explores whether the ownership model can be implemented in the lazy functional programming language STG, which is used in the compilation of Haskell. We implement a simulator for the STG machine with ownership analysis. However, we find that this approach severely restricts the language’s functionality, as it prevents object sharing. We investigate two solutions: deep cloning of objects and a borrowing model. The former has previously been proven to be very time- and space-consuming, while the latter, as we demonstrate, cannot be implemented without additional information about object evaluation or introducing some form of eager evaluation.

Keywords:compiler, non-strict semantics, lazy evaluation, memory management, garbage collection, ownership model

Similar documents

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

Back