# Enhancing Raspberry Pi GPU with Igalias Mesa Optimizations > [! note]- > The content of this page is generated by audio/video transcription and text transformation from the content and links of this source. Source: [https://fosdem.org/2025/schedule/event/fosdem-2025-5553-getting-more-juice-out-from-your-raspberry-pi-gpu/](https://fosdem.org/2025/schedule/event/fosdem-2025-5553-getting-more-juice-out-from-your-raspberry-pi-gpu/) <video src="https://video.fosdem.org/2025/h1302/fosdem-2025-5553-getting-more-juice-out-from-your-raspberry-pi-gpu.av1.webm" controls></video> ## Summary & Highlights: This session focuses on enhancing the performance of Raspberry Pi GPUs through optimizations in the Mesa user-space and kernel drivers, spearheaded by Igalia. The presentation outlines the advancements made in the graphics stack, particularly for Raspberry Pi 4 and 5, using the V3D and V3DV drivers. Significant performance improvements have been achieved, including a 70% boost in certain applications. **Introduction to Raspberry Pi GPU Optimization** Igalia is dedicated to maximizing the potential of Raspberry Pi GPUs by optimizing the graphics stack. The session highlights the importance of these optimizations for embedded systems and the ongoing efforts to enhance the performance of the V3D and V3DV drivers. **Performance Improvements and Benchmarking** The session details various performance enhancements, such as reducing job flushes and leveraging early fragment test optimizations, resulting in significant FPS improvements. Benchmarking scenarios on Raspberry Pi 5 using GFXBench demonstrate these gains, with a focus on Full-HD target resolution. **Utilizing Transparent Huge Pages (THP)** The talk covers the implementation of Transparent Huge Pages to manage large memory pages efficiently, reducing MMU fetches and improving performance in memory-intensive applications. This approach is particularly beneficial for embedded systems with limited memory resources. **Tools and Techniques for Performance Measurement** Igalia introduces tools like Perfetto for performance instrumentation, enabling detailed analysis of system-level and app-level traces. These tools aid in identifying bottlenecks and optimizing performance across the graphics pipeline. **Conclusion and Future Directions** The session concludes with a discussion on the importance of open-source collaboration and the potential for further improvements in Raspberry Pi GPU performance. The speakers encourage continued exploration and development in this area to support eco-social transformation. ## Importance for an eco-social transformation This session is crucial for eco-social transformation as it demonstrates how open-source collaboration can lead to significant technological advancements, making powerful computing accessible and affordable. The optimizations discussed are particularly relevant for eco-social designers working with embedded systems, as they provide tools and methods to enhance performance while maintaining sustainability. Challenges include ensuring widespread adoption of open-source solutions and addressing technical hurdles in optimizing hardware for diverse applications. ## Slides: | | | | --- | --- | | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_001.jpg\|300]] | The first slide introduces the session 'Getting more juice out from your Raspberry Pi GPU' presented by Chema Casanova and Maíra Canal at FOSDEM 2025. It sets the stage for the discussion on optimizing Raspberry Pi GPU performance. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_002.jpg\|300]] | Slide 2 introduces the speakers, Chema Casanova and Maíra Canal, who are open-source developers at Igalia working on the Graphics Team. Their focus is on enhancing the Raspberry Pi graphics stack through improvements in the Mesa user-space and kernel drivers. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_003.jpg\|300]] | Slide 3 discusses the Raspberry Pi 5, highlighting its GPU Broadcom V3D 7.1.7, which shares the same VideoCore architecture as the Raspberry Pi 4 but offers higher clock rates and improved support for certain operations. The slide notes the integration of driver code into existing Mesa and Linux Kernel versions. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_004.jpg\|300]] | Slide 4 provides an overview of the Raspberry Pi GPU driver stack, which is central to the session's focus on optimizing performance through open-source driver enhancements. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_005.jpg\|300]] | Slide 5 explains the role of user-space Mesa3D drivers in enhancing the Raspberry Pi GPU's performance, which is a key component of the optimization strategies discussed in the session. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_006.jpg\|300]] | Slide 6 outlines the conformance of Raspberry Pi 5 GPU graphics APIs, including OpenGL 3.1 and Vulkan 1.3, emphasizing the advancements made since the product's launch and the importance of these APIs in achieving performance improvements. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_007.jpg\|300]] | Slide 7 highlights the performance improvements achieved over the past year, with a focus on GPU-limited scenarios and Full-HD target resolution. It mentions the significant FPS gains realized through various optimizations in the Mesa development process. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_008.jpg\|300]] | Slide 8 details the benchmarking scenario used to measure performance improvements, including the hardware, operating system, kernel, and benchmark tools employed. It provides context for the performance gains discussed in the session. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_009.jpg\|300]] | Slide 9 continues the discussion on performance improvements, underscoring the session's emphasis on optimizing the Raspberry Pi GPU for better performance in various scenarios. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_010.jpg\|300]] | Slide 10 explains tiled-based rendering, a technique used in the Raspberry Pi GPU, detailing the processes involved in GPU BIN and RENDER jobs and how these contribute to performance optimization. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_011.jpg\|300]] | Slide 11 discusses the reduction of job flushes as a performance optimization strategy, highlighting the significant improvement achieved by merging draw calls in the same GPU jobs, which reduces unnecessary loads and stores. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_012.jpg\|300]] | Slide 12 continues the theme of optimizing Raspberry Pi GPU performance, summarizing key strategies and improvements discussed in the session. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_013.jpg\|300]] | Slide 13 focuses on compiler backend optimizations, detailing the reduction in total instructions and the resulting FPS improvements. These optimizations are a critical part of the performance enhancements discussed. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_014.jpg\|300]] | Slide 14 discusses avoiding load/stores on invalidated framebuffers as a performance optimization strategy, leading to a modest FPS improvement by eliminating unnecessary operations. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_015.jpg\|300]] | Slide 15 highlights the use of Early-Z optimization, explaining how enabling this feature under specific conditions can lead to a significant performance improvement by reducing unnecessary depth updates. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_016.jpg\|300]] | Slide 16 discusses avoiding loads/stores with disabled rasterization, particularly beneficial in scenarios using transform feedback. This optimization leads to notable performance gains, especially in specific demos. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_017.jpg\|300]] | Slide 17 revisits the session's theme of maximizing Raspberry Pi GPU performance, summarizing the key strategies and improvements discussed throughout the presentation. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_018.jpg\|300]] | Slide 18 continues the focus on optimizing Raspberry Pi GPU performance, reinforcing the session's emphasis on achieving significant performance gains through various strategies. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_019.jpg\|300]] | Slide 19 presents a graphical representation of FPS improvement over time, illustrating the cumulative effects of the various optimizations discussed in the session across different benchmarks. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_020.jpg\|300]] | Slide 20 introduces performance measurement tools used to analyze and optimize Raspberry Pi GPU performance, a critical aspect of the session's focus on achieving significant performance improvements. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_021.jpg\|300]] | Slide 21 details the use of CPU jobs and timestamp queries as tools for identifying driver bottlenecks, emphasizing their role in achieving synchronized performance analysis and optimization. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_022.jpg\|300]] | Slide 22 discusses Perfetto support, an open-source stack for performance instrumentation, highlighting its role in providing a unified timeline for system-level performance tuning and debugging. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_023.jpg\|300]] | Slide 23 continues the discussion on the tools and techniques used to optimize Raspberry Pi GPU performance, reinforcing the session's emphasis on leveraging open-source resources for significant gains. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_024.jpg\|300]] | Slide 24 introduces kernel work related to Raspberry Pi GPU optimization, setting the stage for a detailed discussion on leveraging kernel-level enhancements to achieve performance improvements. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_025.jpg\|300]] | Slide 25 explains the concept of Super Pages and their potential performance benefits, highlighting the challenges and solutions involved in implementing this feature for Raspberry Pi GPUs. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_026.jpg\|300]] | Slide 26 discusses the use of Transparent Huge Pages (THP) for managing large memory pages, explaining how this approach contributes to performance improvements by reducing memory management overhead. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_027.jpg\|300]] | Slide 27 highlights the average performance improvements achieved through the use of THP, emphasizing the importance of memory management strategies in optimizing Raspberry Pi GPU performance. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_028.jpg\|300]] | Slide 28 introduces a video demonstration of SuperPages, providing a visual representation of the performance improvements discussed in the session. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_029.jpg\|300]] | Slide 29 continues the video demonstration of SuperPages, reinforcing the session's emphasis on achieving significant performance gains through innovative memory management strategies. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_030.jpg\|300]] | Slide 30 discusses tailoring THP to specific memory block sizes, explaining how this customization contributes to optimized memory usage and performance improvements for Raspberry Pi GPUs. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_031.jpg\|300]] | Slide 31 provides technical details on configuring THP policies, highlighting the flexibility and customization options available for optimizing memory management in Raspberry Pi GPUs. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_032.jpg\|300]] | Slide 32 opens the floor for questions, inviting audience engagement and discussion on the topics presented in the session. | ![[FOSDEM 2025/assets/Getting-more-juice-out-from-your-Raspberry-Pi-GPU/preview_033.jpg\|300]] | Slide 33 concludes the session, summarizing the key points and emphasizing the potential for continued exploration and development in optimizing Raspberry Pi GPU performance. ## Links [Slides PDF](https://fosdem.org/2025/events/attachments/fosdem-2025-5553-getting-more-juice-out-from-your-raspberry-pi-gpu/slides/238057/20250201-_0Ym02Fd.pdf) [Video recording (AV1/WebM)](https://video.fosdem.org/2025/h1302/fosdem-2025-5553-getting-more-juice-out-from-your-raspberry-pi-gpu.av1.webm) [Video recording (MP4)](https://video.fosdem.org/2025/h1302/fosdem-2025-5553-getting-more-juice-out-from-your-raspberry-pi-gpu.av1.mp4)