libunwind official github repo (in need of new / additional maintainer, mail/open issue if interested)
libunwind official github repo (in need of new / additional maintainer, mail/open issue if interested)
libunwind is a portable and efficient C API for determining the current call chain of ELF program threads of execution and for resuming execution at any point in that call chain. The API supports both local (same process) and remote (other process) operation.
The API is useful in a number of applications, including but not limited to the following.
setjmp()/longjmp()
libunwind optionally provides an alternative implementation of the
setjmp()/longjmp() functionality of the C standard library.This library supports several architecture/operating-system combinations:
| System | Architecture | Status |
|---|---|---|
| Linux | x86-64 | ✓ |
| Linux | x86 | ✓ |
| Linux | ARM | ✓ |
| Linux | AArch64 | ✓ |
| Linux | Alpha | ✓ |
| Linux | PPC32 | ✓ |
| Linux | PPC64 | ✓ |
| Linux | PPC64LE | ✓ |
| Linux | s390x | ✓ |
| Linux | SPARC64 | ✓ |
| Linux | SuperH | ✓ |
| Linux | IA-64 | ✓ |
| Linux | PA-RISC | Works well, but C library missing unwind-info |
| Linux | MIPS | ✓ |
| Linux | RISC-V | ✓ |
| Linux | LoongArch | 64-bit only |
| HP-UX | IA-64 | Mostly works, but known to have serious limitations |
| FreeBSD | x86-64 | ✓ |
| FreeBSD | x86 | ✓ |
| FreeBSD | AArch64 | ✓ |
| FreeBSD | PPC32 | ✓ |
| FreeBSD | PPC64 | ✓ |
| FreeBSD | RISC-V | ✓ |
| QNX | Aarch64 | ✓ |
| QNX | x86-64 | ✓ |
| Solaris | x86-64 | ✓ |
This library uses Meson as its build system. It can be built and installed with the following commands:
$ meson setup build --prefix=PREFIX
$ meson compile -C build
$ meson install -C buildwhere PREFIX is the installation prefix. By default, a prefix of
/usr/local is used, such that libunwind.a is installed in
/usr/local/lib and unwind.h is installed in /usr/local/include.
An Autotools build is still provided, but is deprecated and planned for removal in a future release. New usage should build with Meson instead.
$ autoreconf -i # Needed only for building from git. Depends on libtool.
$ ./configure --prefix=PREFIX
$ make
$ make installAfter building the library, you can run a set of regression tests with:
$ meson test -C buildWith Autotools, use make check instead.
This distribution includes a few simple performance tests which give some idea of the basic cost of various libunwind operations. After building the library, you can run these tests with the following command:
$ meson test -C build --benchmarkWith Autotools, run make perf from the tests directory instead.
Please raise issues and pull requests through the GitHub repository: .
No open issues yet, or sync has not completed.