In the quest for a next-generation smart-home accessory, there is a noticeable trend towards replacing traditional System-on-Chip (SoC) architectures with more cost-effective and viable System-in-Package (SiP) solutions. These SiP solutions, however, come with certain trade-offs. They incorporate integrated memory, which simplifies the overall complexity associated with developing the final product board. Nevertheless, this integration also imposes limitations on the options available for the RAM chip. This issue has led to an increasingly pressing need for efficient memory management in such devices. Thanks to our collaboration with Bticino, we studied this problem in greater depth, identifying each aspect that constitutes a traditional embedded device using a System in Package. Conscious of the strengths and weaknesses of the devices, we explore various possible solutions to the challenges encountered while endeavouring to minimise interference with their performance and functionalities. We hypothesise that the careful and strategic application of advanced tuning techniques, coupled with effective compression mechanisms at the kernel level, may ultimately enable the seamless integration of dynamic memory swapping capabilities. We perform a comprehensive analysis of RAM consumption on an existing Linux-based device, specifically selecting and simulating representative workloads that closely mimic real-world usage scenarios. Subsequently, we evaluate key tuning techniques applicable to the mainline kernel that may be effectively implemented in production settings. In addition, we introduce a novel compression-enhanced swapping strategy referred to as selective swap. Our experimental results indicate that with these new techniques, we can achieve up to a 33% reduction in the memory footprint, although with a faint reduction in performance. In scenarios that involve more balanced devices, an alternative configuration allows us to sustain performance levels that are on par with those of the original baseline system, while also achieving a notable reduction in memory usage of 15%. These findings contribute to the expanding body of knowledge surrounding the optimisation of resource-constrained devices, thereby paving the way for the next generation of smart, efficient, and responsive embedded systems.
Nella ricerca di un dispositivo smart-home di nuova generazione, si nota una tendenza a sostituire le tradizionali architetture System-on-Chip (SoC) con soluzioni System-in-Package (SiP) più convenienti e di più facile implementazione. Tuttavia, queste soluzioni SiP presentano alcuni compromessi. Incorporando il chip di memoria, viene semplificato lo sviluppo del circuito stampato (PCB) del prodotto finale. Tuttavia, questa integrazione impone anche delle limitazioni alle opzioni disponibili per il chip RAM. Questo problema ha portato a una necessità sempre più pressante per una maggiore efficenza di utilizzo della memoria in tali dispositivi. Grazie alla nostra collaborazione con Bticino, abbiamo studiato questo problema in modo più approfondito, identificando ogni aspetto di un dispositivo embedded tradizionale che utilizza un System in Package. Consapevoli dei punti di forza e di debolezza dei dispositivi, abbiamo esplorato varie possibili soluzioni alle sfide incontrate, cercando al contempo di ridurre al minimo l'interferenza con le loro prestazioni e funzionalità. In questa tesi abbiamo ipotizzato che l'applicazione strategica di tecniche di ottimizzazione avanzate, abbinate a efficaci meccanismi di compressione a livello di kernel, possa portare ad una integrazione delle capacità di swapping dinamico della memoria. Per testare queste ipotesi siamo partiti da un'analisi completa del consumo di RAM su un dispositivo Linux esistente, selezionando e simulando specificamente carichi di lavoro rappresentativi che imitano da vicino gli scenari di utilizzo del mondo reale. Successivamente, abbaimo valutato le principali tecniche di ottimizzazione applicabili al kernel principale che possono essere implementate efficacemente in contesti di produzione. Inoltre, abbiamo introdotto una nuova strategia di swapping che utilizza la compressione in ram, denominata Selective Swap (swap selettiva). I nostri risultati sperimentali indicano che con queste nuove tecniche, possiamo ottenere fino al 33% di riduzione del consumo di memoria, sebbene con una lieve riduzione delle prestazioni. In scenari che coinvolgono dispositivi più bilanciati, una configurazione alternativa con la swap selettiva attivata, ci consente invece di mantenere livelli di prestazioni pari a quelli del sistema di base originale, ottenendo comunque una notevole riduzione dell'utilizzo della memoria del 15%. Questi risultati contribuiscono all'espansione delle conoscenze sull'ottimizzazione dei dispositivi con risorse limitate, aprendo così la strada alla prossima generazione di sistemi embedded intelligenti, efficienti e reattivi.
Exploring techniques for reducing memory footprint without degrading performance on Linux
BOTTI, LUCA
2023/2024
Abstract
In the quest for a next-generation smart-home accessory, there is a noticeable trend towards replacing traditional System-on-Chip (SoC) architectures with more cost-effective and viable System-in-Package (SiP) solutions. These SiP solutions, however, come with certain trade-offs. They incorporate integrated memory, which simplifies the overall complexity associated with developing the final product board. Nevertheless, this integration also imposes limitations on the options available for the RAM chip. This issue has led to an increasingly pressing need for efficient memory management in such devices. Thanks to our collaboration with Bticino, we studied this problem in greater depth, identifying each aspect that constitutes a traditional embedded device using a System in Package. Conscious of the strengths and weaknesses of the devices, we explore various possible solutions to the challenges encountered while endeavouring to minimise interference with their performance and functionalities. We hypothesise that the careful and strategic application of advanced tuning techniques, coupled with effective compression mechanisms at the kernel level, may ultimately enable the seamless integration of dynamic memory swapping capabilities. We perform a comprehensive analysis of RAM consumption on an existing Linux-based device, specifically selecting and simulating representative workloads that closely mimic real-world usage scenarios. Subsequently, we evaluate key tuning techniques applicable to the mainline kernel that may be effectively implemented in production settings. In addition, we introduce a novel compression-enhanced swapping strategy referred to as selective swap. Our experimental results indicate that with these new techniques, we can achieve up to a 33% reduction in the memory footprint, although with a faint reduction in performance. In scenarios that involve more balanced devices, an alternative configuration allows us to sustain performance levels that are on par with those of the original baseline system, while also achieving a notable reduction in memory usage of 15%. These findings contribute to the expanding body of knowledge surrounding the optimisation of resource-constrained devices, thereby paving the way for the next generation of smart, efficient, and responsive embedded systems.File | Dimensione | Formato | |
---|---|---|---|
Botti_Luca___Article_Format_Thesis___Scuola_di_Ingegneria_Industriale_e_dell_Informazione___Politecnico_di_Milano.pdf
accessibile in internet per tutti
Descrizione: Testo della tesi
Dimensione
2.12 MB
Formato
Adobe PDF
|
2.12 MB | Adobe PDF | Visualizza/Apri |
Botti_Luca___Executive_Summary___Scuola_di_Ingegneria_Industriale_e_dell_Informazione___Politecnico_di_Milano.pdf
accessibile in internet per tutti
Descrizione: Testo dell'executive summary
Dimensione
619.42 kB
Formato
Adobe PDF
|
619.42 kB | Adobe PDF | Visualizza/Apri |
I documenti in POLITesi sono protetti da copyright e tutti i diritti sono riservati, salvo diversa indicazione.
https://hdl.handle.net/10589/234945