# Profile the Linux kernel with Arm Streamline

## In this learning path

- [Introduction](https://learn.arm.com/learning-paths/embedded-and-microcontrollers/streamline-kernel-module/)
- [Profile Linux kernel modules with Arm Streamline](https://learn.arm.com/learning-paths/embedded-and-microcontrollers/streamline-kernel-module/1_overview/)
- [Set up your environment](https://learn.arm.com/learning-paths/embedded-and-microcontrollers/streamline-kernel-module/2_build_kernel_image/)
- [Build the out-of-tree kernel module](https://learn.arm.com/learning-paths/embedded-and-microcontrollers/streamline-kernel-module/3_oot_module/)
- [Profile the out-of-tree kernel module](https://learn.arm.com/learning-paths/embedded-and-microcontrollers/streamline-kernel-module/4_sl_profile_oot/)
- [Integrate a custom character device driver into the Linux kernel](https://learn.arm.com/learning-paths/embedded-and-microcontrollers/streamline-kernel-module/5_intree_kernel_driver/)
- [Profile the in-tree kernel driver](https://learn.arm.com/learning-paths/embedded-and-microcontrollers/streamline-kernel-module/6_sl_profile_intree/)
- [Use Streamline with the Statistical Profiling Extension](https://learn.arm.com/learning-paths/embedded-and-microcontrollers/streamline-kernel-module/7_sl_spe/)
- [Summary](https://learn.arm.com/learning-paths/embedded-and-microcontrollers/streamline-kernel-module/8_summary/)
- [Next Steps](https://learn.arm.com/learning-paths/embedded-and-microcontrollers/streamline-kernel-module/_next-steps/)

## About this Learning Path

|  |  |
| --- | --- |
| Skill level: | Advanced |
| Reading time: | 1 hr |
| Last updated: | 06 Oct 2026 |

|  |  |
| --- | --- |
| Author: | Yahya Abouelseoud , Arm |
| Arm IP: | [Cortex-A](https://support.arm.com/?tab=compute-ip&Product%20Type=Application%20Processors) |
| Tags: | [Performance and Architecture](https://learn.arm.com/tag/performance-and-architecture) [Linux](https://learn.arm.com/tag/linux) [Arm Streamline](https://learn.arm.com/tag/arm-streamline) [Arm Performance Studio](https://learn.arm.com/tag/arm-performance-studio) [Linux kernel](https://learn.arm.com/tag/linux-kernel) [Performance analysis](https://learn.arm.com/tag/performance-analysis) |

### Who is this for?
This is an advanced topic for developers and performance engineers interested in profiling Linux kernel performance.

### What will you learn?
After completing this Learning Path, you'll be able to perform the following tasks:
- Understand why profiling Linux kernel modules is important for performance and stability
- Set up and use Arm Streamline to profile the Linux kernel
- Profile both out-of-tree and in-tree kernel modules on Arm-based systems
- Analyze profiling data to find and address performance bottlenecks
- Use the Statistical Profiling Extension (SPE) for deeper kernel profiling insights

### Prerequisites
Before starting, you'll need the following prerequisites:
- Basic understanding of Linux kernel development and module programming
- Arm-based Linux target device (such as a Raspberry Pi, BeagleBone, or similar board) with Secure Shell (SSH) access
- A host machine that meets [Buildroot system requirements](https://buildroot.org/downloads/manual/manual.html#requirement)

### Summary
You’ll profile Linux kernel code on an Arm-based system with Arm Streamline. First, you’ll build and exercise a cache-unfriendly out-of-tree character-device module, then inspect CPU, cycle, memory, and cache metrics. Next, you’ll profile the driver in-tree with `vmlinux` symbols and, on supported targets, use SPE for deeper kernel analysis.

### Frequently asked questions

**Which file should I add in Streamline to analyze an in-tree driver?**

Add the kernel’s `vmlinux` file in the capture settings. Doing so enables analysis of function calls, call paths, and specific kernel code sections.

**How do I know Streamline is capturing my out-of-tree module?**

During the workload, expect samples attributed to your module’s functions. You should also see changes in metrics such as memory access and cache misses while the device is exercised.

**What result should I expect when profiling the cache‑unfriendly module?**

Streamline should show sampling activity during the device operations and elevated cache‑related metrics due to the column‑major traversal. Use these indicators to locate hotspots and costly memory access patterns.

**Do I need to install the Buildroot dependencies on an AArch64 host?**

Yes. Run the package installation on an AArch64-based Linux system before building.

**When should I enable SPE in this workflow?**

Use SPE when deeper kernel profiling insights are needed beyond regular sampling. The Learning Path introduces SPE on supported targets to extend kernel execution analysis.
