[lldb-dev] did anyone konw LLDB support lldb + openocd to run dotest.py in bare board like ARM or other non-x86 architecture?

cui bixiong via lldb-dev lldb-dev at lists.llvm.org
Thu Oct 26 23:40:43 PDT 2017

Hi :

    I build a armhf qemu enviroment to test ARM lldb + lldb-server
testsuite.  source code base on LLVM + LLDB + LLD + CLANG formal release

    Target: lldb-server platform --listen *:3333 --server

    Host :

    (lldb) platform select remote-linux
    Platform: remote-linux
    Connected: no
    (lldb) platform connect connect://
    Platform: remote-linux
    Triple: arm-*-linux-gnueabihf
    OS Version: 3.2.0 (3.2.0-4-vexpress)
    Kernel: #1 SMP Debian 3.2.51-1
    Hostname: debian-armhf.""
    Connected: yes
    WorkingDir: /root
    (lldb) file ./hello.exe
    Current executable set to './hello.exe' (arm).
    (lldb) log enable gdb-remote packets
    (lldb) process launch
    history[1] tid=0x6192 <   1> send packet: +
    history[2] tid=0x6192 <  19> send packet: $QStartNoAckMode#b0
    history[3] tid=0x6192 <   1> read packet: +
    history[4] tid=0x6192 <   6> read packet: $OK#9a
    history[5] tid=0x6192 <   1> send packet: +
    history[6] tid=0x6192 <  13> send packet: $qHostInfo#9b
    history[7] tid=0x6192 < 297> read packet:
    history[8] tid=0x6192 <  18> send packet: $qGetWorkingDir#91
    history[9] tid=0x6192 <  14> read packet: $2f726f6f74#a4
    history[10] tid=0x6192 <  19> send packet: $qQueryGDBServer#cb
    history[11] tid=0x6192 <   7> read packet: $E04#a9
    history[12] tid=0x6192 <  73> send packet:
history[13] tid=0x6192 <   7> read packet: $E03#a8
history[14] tid=0x6192 <  69> send packet:
    history[15] tid=0x6192 <   7> read packet: $E03#a8
<  36> send packet: $qLaunchGDBServer;host:mtkslt202;#b1
    error: unable to launch a GDB server on 'debian-armhf.""'

     i show host and port is uncorrect, is it a bug?

Best Regards

On Tue, Oct 24, 2017 at 11:04 PM, Greg Clayton <clayborg at gmail.com> wrote:

> On Oct 24, 2017, at 12:02 AM, cui bixiong <cuibixiong at gmail.com> wrote:
> Hi
>     sorry, i'm confuse, in my mind, lldb-server maybe like gdb-server,
> running on Linux-like platform  listening RSP command which send form gdb
> and use ptrace syscall to debug which you want to debug program
>     is it support remote download to batch mode run all testsuite?
> certainly i think reset baseboard is very important feature too,  but in
> lldb-server maybe not support currently i guess.
> Yes lldb-server does support a full connection to a remote OS. On
> baseboards you are typically debugging the entire OS so lldb-server won't
> work because you have to OS to run it in the background. Supporting the
> test suite on baseboards will take some effort.
> Best Regards
> --cuibixiong
> On Mon, Oct 23, 2017 at 11:06 PM, Greg Clayton <clayborg at gmail.com> wrote:
>> > On Oct 22, 2017, at 6:21 AM, cuibixiong via lldb-dev <
>> lldb-dev at lists.llvm.org> wrote:
>> >
>> > Hi
>> >
>> >       did anyone konw LLDB support lldb + openocd to run dotest.py in
>> bare board like ARM or other non-x86 architecture?
>> We run the test suite on iOS devices using the platform stuff. This
>> requires a running lldb-server on the remote system, so we only have the
>> test suite running when we have the lldb-server running in platform mode on
>> the other side. For this to work with baseboards, we would need the JTAG
>> box to respond to many GDB remote protocol packets that "lldb-server
>> platform" implements. I am sure for baseboards the test suite would need to
>> be modified. A few ideas there:
>> - Have the test suite watch for a triple with no os (like
>> "arm64-none-none") and have it go into a baseboard mode
>> - Many tests that might rely on writing to files, reading from files for
>> stdin, and others, would need to be skipped in this mode
>> - Any tests that build and debug shared libraries would either need to be
>> modified to build multiple static binaries or skipped
>> - We might need to make a Bareboard platform and would load the ELF files
>> into memory instead of copying them over like the current platforms do
>> So there would be quite a lot of modifications required to get the test
>> suite running. We will be happy to help you if you choose to try this.
>> Greg Clayton
>> >
>> > Best Regards
>> > —cuibixiong
>> > _______________________________________________
>> > lldb-dev mailing list
>> > lldb-dev at lists.llvm.org
>> > http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-dev
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/lldb-dev/attachments/20171027/8d762ad2/attachment.html>

More information about the lldb-dev mailing list