---
title: "Extending LLDB to Debug Applications That Span CPUs and GPUs"
description: "LLDB gains a vendor-neutral accelerator plugin architecture in lldb-server that represents the CPU and GPU as separate debugger targets, each with its own architecture, threads, registers and address space, while presenting them in one debugging session."
url: "https://swe.quest/articles/extending-lldb-to-debug-applications-that-span-cpus-and-gpus-36dc33c7472e000a"
canonical: "https://engineering.fb.com/2026/11/09/developer-tools/extending-lldb-to-debug-applications-that-span-cpus-and-gpus/"
source: "Meta Engineering"
published: "2026-11-09"
difficulty: "hard"
kind: "Deep dive"
reading_minutes: 6
tags: ["debugging","developer-tools","hardware","open-source"]
---

# Extending LLDB to Debug Applications That Span CPUs and GPUs

A post on [Meta Engineering](https://swe.quest/sources/meta.md), published 2026-11-09, 6 min read, Deep dive. Original: [https://engineering.fb.com/2026/11/09/developer-tools/extending-lldb-to-debug-applications-that-span-cpus-and-gpus/](https://engineering.fb.com/2026/11/09/developer-tools/extending-lldb-to-debug-applications-that-span-cpus-and-gpus/)

## Summary

LLDB gains a vendor-neutral accelerator plugin architecture in lldb-server that represents the CPU and GPU as separate debugger targets, each with its own architecture, threads, registers and address space, while presenting them in one debugging session. Plugins set internal host breakpoints to detect runtime events, initialize the vendor's device debugging API, and hand LLDB a second GDB-remote connection for the device target, so existing abstractions handle device threads, memory, modules and breakpoints. A mock accelerator plugin allows hardware-independent testing in the LLVM suite, core-dump plugins support postmortem debugging, and most of the framework has been upstreamed. The aim is that supporting new hardware needs only a vendor plugin rather than a separate debugger like ROCgdb or CUDA-GDB.

Written by swe.quest, not by the author.

**Difficulty:** Hard: written for specialists in the field

## Topics

- [Debugging](https://swe.quest/tags/debugging.md) (Engineering practices)
- [Developer tools](https://swe.quest/tags/developer-tools.md) (Engineering practices)
- [Hardware](https://swe.quest/tags/hardware.md) (Infrastructure)
- [Open source](https://swe.quest/tags/open-source.md) (Engineering practices)

## Prerequisites

- debugger internals
- GDB remote protocol
- GPU execution model ([easy posts on Hardware](https://swe.quest/tags/hardware.md?difficulty=easy))

## Keywords

LLDB, lldb-server, GDB remote protocol, LLVM, HIP, ROCgdb, CUDA-GDB

## Related posts

- [Progress Report: Linux 7.3](https://swe.quest/articles/progress-report-linux-7-3-128fc5535e6dbd29.md): Asahi Linux · 2026-11-07 · Hard · 14 min read · Linux, Hardware, Virtualization, Memory management, Games
  Asahi Linux's 7.3-cycle report covers upstream submission of the macaudio and AVD (~13,000 lines) drivers, initial M4 Pro/Max and M5 Devicetrees, and M3 support going generally available with DCP enabling sleep and the notch area. m1n1 now runs three EL1 VMs (macOS, SPTM, and the Secure Kernel with Exclaves) to reverse engineer M5 macOS.
- [The Debugger is Here](https://swe.quest/articles/the-debugger-is-here-13c8e56684fd9503.md): Zed · 2025-06-18 · Medium · 7 min read · Developer tools, Debugging, Rust
  Zed now ships a native debugger built on the Debug Adapter Protocol, with out-of-the-box support for Rust, C/C++, JavaScript, Go and Python.
- [Progress Report: Linux 6.17](https://swe.quest/articles/progress-report-linux-6-17-b2015482a02e4cc1.md): Asahi Linux · 2025-10-24 · Easy · 10 min read · Linux, Hardware, Operating systems, Rust, Open source
  The Apple SMC core driver, along with its GPIO and reboot controllers, has landed upstream in Linux 6.17, joining Devicetree schema changes that stabilize how the future GPU driver reads firmware data.
- [Reverse debugging at scale](https://swe.quest/articles/reverse-debugging-at-scale-38ad4795201fdcca.md): Meta Engineering · 2021-04-27 · Hard · 7 min read · Debugging, Developer tools, Hardware, Linux, Performance engineering
  Meta continuously records Intel Processor Trace (Intel PT) data for all running processes in production, keeping it in a bounded circular buffer.
- [Hardening eBPF for runtime security: Lessons from Datadog Workload Protection](https://swe.quest/articles/hardening-ebpf-for-runtime-security-lessons-from-datadog-workload-protection-d7f876ff0025b179.md): Datadog Engineering · 2026-01-07 · Hard · 34 min read · Linux, Threat detection, Security, Operating systems, Performance engineering
  Five years of running Datadog Workload Protection, an eBPF-based runtime security agent supporting kernels from 4.15 to 6.18, distilled into six production lessons.

Browse: [Latest posts](https://swe.quest/index.md) · [Topics](https://swe.quest/tags.md) · [Sources](https://swe.quest/sources.md) · [Topic map](https://swe.quest/map.md) · [Site guide (llms.txt)](https://swe.quest/llms.txt)
