AIX

AIX

Connect with fellow AIX users and experts to gain knowledge, share insights, and solve problems.

 View Only

LLDB Tech Preview on AIX: Redefining your debugging Experience

By Dhruv Srivastava posted 2 days ago

  

If you debug complex applications on AIX, chances are that you’ve relied heavily on dbx or gdb. These debuggers have served us well, but today we’re thrilled to announce a significant advancement in the debugging toolkit on AIX: 

Starting with IBM® AIX® 7.3 Technology Level 3, a Tech Preview of the Low-Level Debugger (LLDB) is being introduced. LLDB is a product of The LLVM project, which is a collection of modular and reusable compiler and toolchain technologies. AIX 7.3 TL3 SP1 showcases a limited set of LLDB features as a Tech Preview. Currently, LLDB is primarily aligned with the adoption of the LLVM-based compiler, IBM Open XL C/C++, and supports source-level debugging exclusively for applications compiled with Open XL. 

Why LLDB?  

LLDB, is a modern, modular, and high-performance debugger designed to meet the demands of today’s complex software systems. It offers: 

  1. Comprehensive Language Support: Optimized for modern versions of C, C++, Objective-C, and more. 

  1. Performance and Usability: Fast, responsive, and equipped with a more user friendly and interactive command-line interface, varying and diverse command syntax. 

  1. Extensibility: Built with clean APIs, enabling better integration into custom tools and automation workflows. 

  1. Active Development: Maintained by an active LLVM community, ensuring continuous innovation and feature enhancements. 

  1. Modular Architecture: Designed with independently functioning components, promoting maintainability and structured development. 

What’s Included in the Tech Preview: 

This initial release of LLDB on AIX includes essential debugging features such as: 

  1. Debugging 64-Bit AIX XCOFF applications. 

  1. Support for debugging 64-bit AIX coredump files. 

  1. Debugging live 64-bit processes via attach functionality. 

  1. Most of the commonly used debugging commands on the above three fronts, in all their existing formats, such as: 

    1. breakpoints (b <function name>, b <line-no>, breakpoint list and others)

    2. run, next, step, step in, step over and others

    3. register commands (such as register info, register read, register write and others)

    4. memory commands (memory read <address>, memory region <address> etc), disassemble, nexti, stepi

    5. frame variable x, frame info, bt (OR thread backtrace)

    6. Command auto-completion, command aliasing and loading commands from input files etc.

    7. help - for an exhaustive well detailed list of lldb commands 

5. LLDB source level debugging is currently only supported with OpenXL compiled binaries.

Getting Started: 

  1. Download the Package from:  https://www.ibm.com/resources/mrs/assets?source=aixbp
    Keep the fileset in your directory and run  installp  on  lldb.rte  with the required options. 

  1. Launch LLDB with your target application/binary as shown in the Sneak peek section’s images. You can also access the README from /usr/opt/lldb/README 

Explore the commands are per your need from the following links: 

  1. https://lldb.llvm.org/man/lldb.html 

Current Limitations (Planned for Upcoming Releases): 

While the core functionalities are now available, LLDB on AIX is still evolving. As this is an early alpha release, it’s important to note that this Tech Preview represents an early milestone, and development is actively ongoing to expand its capabilities. 

In this regard, some of the key limitations for this tech preview are: 

  1. Multi-threaded application debugging. 

  1. 32-bit application support. 

  1. Watchpoints. 

  1. Advanced LLDB features like Python scripting, Remote debugging, Cross-debugging and others. 

Stay tuned — more powerful features are just around the corner. 

Here’s a Quick Sneak Peek: 
 
Below are a few example snapshots to give you a preview of some debugging sessions, their UI and use cases:

Picture

Fig 1. Debugging an XCOFF binary

Picture

Fig 2. Debugging an AIX Core dump

Picture

Fig 3. Debugging an attached process

 

0 comments
31 views

Permalink