AIX

AIX

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


#Power
#Power
#Operatingsystems
#Servers
 View Only
  • 1.  LLDB 22.0.0 - executable doesn't exist

    Posted 11/14/25 02:49 PM
    Edited by Emanuel Reisinger 11/14/25 02:49 PM

    Hi,

    When lldb is started without absolute path it cannot load the executable on run.

    Setup:

    er@vega:/sources/er/lldb# lldb -version
    lldb version 22.0.0git (https://github.com/Dhruv-Srivastava-IBM/lldb-for-aix.git revision 17055ab537d7673e7640d0bd993c5ad1c64fe938)
      clang revision 17055ab537d7673e7640d0bd993c5ad1c64fe938
      llvm revision 17055ab537d7673e7640d0bd993c5ad1c64fe938

    er@vega:/sources/er/lldb# which lldb
    /opt/lldb/bin/lldb
    er@vega:/sources/er/lldb# ls -l /opt/lldb*
    lrwxrwxrwx    1 root     system           31 Nov 14 20:38 /opt/lldb -> /opt/lldb-aix-pre-release-1.0.x

    /opt/lldb-aix-pre-release-1.0.x:
    total 0
    drwxr-xr-x    2 root     system          256 Nov 11 11:34 bin

    er@vega:/sources/er/lldb# echo $PATH
    ...:/opt/lldb/bin:...
    er@vega:/sources/er/lldb#

    The failure:

    er@vega:/sources/er/lldb# file test
    test: executable (RISC System/6000) or object module not stripped
    er@vega:/sources/er/lldb# lldb test

    (lldb) target create "test"
    Current executable set to '/sources/er/lldb/test' (powerpc64).
    (lldb) b main
    Breakpoint 1: where = test`main + 44 at test.C:9, address = 0x000000001000074c
    (lldb) r
    error: executable doesn't exist: '(empty)'
    (lldb) q

    But when starting lldb with absolute path it works:

    er@vega:/sources/er/lldb# /opt/lldb/bin/lldb test
    (lldb) target create "test"
    Current executable set to '/sources/er/lldb/test' (powerpc64).
    (lldb) b main
    Breakpoint 1: where = test`main + 44 at test.C:9, address = 0x000000001000074c
    (lldb) r
    Process 10158724 launched: '/sources/er/lldb/test' (powerpc64)
    Process 10158724 stopped
    * thread #1, name = 'test', stop reason = breakpoint 1.1
        frame #0: 0x000000001000074c test`main(argc=1, argv=0x2ff2295000000001) at test.C:9
       6     int main(int argc, char **argv)
       7     {
       8       char text[len];
    -> 9       memset(text, 'a', len-1);
       10      text[len-1]='\0';
       11      printf("%s\n", text);
       12    }
    (lldb) q
    Quitting LLDB will kill one or more processes. Do you really want to proceed: [Y/n]



    -------------------------------------------

    Emanuel Reisinger

    cargoNET // Axians ICT Austria GmbH



  • 2.  RE: LLDB 22.0.0 - executable doesn't exist

    Posted 11/17/25 09:49 AM

    Hi Emanuel,

    Thank you for reaching out.

    Regarding the issues you're encountering, it appears as they are specific to 32-bit applications.

    LLDB for AIX is currently under active development, and support for debugging 32-bit applications is already planned for upcoming releases.

    In the meantime, we kindly recommend testing with 64-bit applications (using the -m64 compiler flag) to see if the issue persists. Please let us know your results-your feedback is greatly appreciated and helps us make LLDB more robust.

    Thanks,
    Hemang Gadhavi



    ------------------------------
    Hemang Gadhavi
    ------------------------------



  • 3.  RE: LLDB 22.0.0 - executable doesn't exist

    Posted 11/17/25 11:10 AM

    Hi Hemang,

    The issue still persists with 64-bit applications.

    er@paris:/sources/er/lldb# file test
    test: 64-bit XCOFF executable or object module not stripped
    er@paris:/sources/er/lldb# lldb test
    (lldb) target create "test"
    Current executable set to '/sources/er/lldb/test' (powerpc64).
    (lldb) b main
    Breakpoint 1: where = test`main + 28 at test.C:9, address = 0x000000010000091c
    (lldb) r
    error: executable doesn't exist: '(empty)'
    (lldb) q

    By the way, our applications on AIX are all built as 64-bit applications. Only for the simple test we missed the -m64 flag. But good to know that there is a difference in debugging support.

    Regards,



    ------------------------------
    Emanuel Reisinger
    Axians ICT Austria GmbH
    ------------------------------



  • 4.  RE: LLDB 22.0.0 - executable doesn't exist

    Posted 11/18/25 12:45 PM
    Edited by Dhruv Srivastava 11/18/25 12:51 PM

    Hi Emanuel,

    We are pleased to inform you that a newer version of LLDB, which includes a fix for the reported issue, is available.

    We will share this updated package with IBM Support so that you can evaluate it. Please ensure that you use the updated script included in the package for a smooth uninstallation and installation process.

    This will help ensure that the binaries are correctly placed in your environment.

    Best Regards,



    ------------------------------
    Dhruv Srivastava

    LLDB Development

    ------------------------------



  • 5.  RE: LLDB 22.0.0 - executable doesn't exist

    Posted 05/21/26 09:29 AM

    Hi Dhruv,

    Would you be able to say which version of LLDB this fix was introduced? 

    We're seeing what appears to be a similar problem, both attempting to attach to a process and starting from within lldb using 

    $ lldb --version
    lldb version 22.0.0git (https://github.com/Dhruv-Srivastava-IBM/lldb-for-aix.git revision b6dac6ca31d07f4522348beee184e075224b0f47)
      clang revision b6dac6ca31d07f4522348beee184e075224b0f47
      llvm revision b6dac6ca31d07f4522348beee184e075224b0f47

    Would you also be able to comment on why lslpp seems to report a different version for lldb?

    $ lldb --version
    lldb version 22.0.0git (https://github.com/Dhruv-Srivastava-IBM/lldb-for-aix.git revision b6dac6ca31d07f4522348beee184e075224b0f47)
      clang revision b6dac6ca31d07f4522348beee184e075224b0f47
      llvm revision b6dac6ca31d07f4522348beee184e075224b0f47
    $ lslpp -lc | grep lldb
    /usr/lib/objrepos:lldb.rte:21.1.3.0::COMMITTED:I:LLVM Debugger:
    /etc/objrepos:lldb.rte:21.1.3.0::COMMITTED:I:LLVM Debugger:

    Thanks,

    Silas



    ------------------------------
    Silas Poulson
    ------------------------------



  • 6.  RE: LLDB 22.0.0 - executable doesn't exist

    Posted 19 days ago
    Edited by Dhruv Srivastava 19 days ago

    Hi Silas, 
    Although we have already communicated over mail, but just to update, the latest released version for lldb is now 22.1.2.5
    lldb --version
     AIX pre-release VRMF: 22.1.2.5 
    lldb version 23.0.0git (https://github.com/Dhruv-Srivastava-IBM/lldb-for-aix.git revision f8fd5a1abf897aa649cd72bdaad825e3874f37bc)
      clang revision f8fd5a1abf897aa649cd72bdaad825e3874f37bc
      llvm revision f8fd5a1abf897aa649cd72bdaad825e3874f37bc
    We have more updates, further details of which, we can discuss over mail.
    Thanks, 



    ------------------------------
    Dhruv Srivastava
    LLDB Development
    ------------------------------