This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

How to configure DSTREAM to debug linux application?

Run->Debug Configurations->Linux Application Debug->Connect to already running gdbserver

(1) how to run gdbserver in this case

     I use a separate USB to connect to phone usb port, together with a JTAG connection to DSTREAM box

     I did an adb shell, and do

     gdbserver :5039 --attach pid, by default the ip is localhost which is 127.0.0.1

(2) how to set gdbserver address (TCP)

     I put in 127.0.0.1

(3) port is set to 5039

but after I use apply and debug

DSTREAM gives out Unable to connect to DSTREAM

   Reason:

   Failed to connect to the device

   Unable to connect to device gdbserver

   Unable to connect to gdbserver at 127.0.0.1 on port 5039

Parents
  • Hi again Tony,

    Reading your comment again (from my laptop, not my phone!), I see you refer to a "memory breakpoint", by which I believe you mean that you are checking if a write occurs to a particular address at any point (we call these "watchpoints"). You are correct that a software implementation of these are terrible for performance, as the debugger has to check after every instruction whether or not that address was written to. You should be able to use DSTREAM in that manner to catch a write to a given address, by using the debugger command:

    awatch <address>

    (or in the memory window -> toggle watchpoint)

Reply
  • Hi again Tony,

    Reading your comment again (from my laptop, not my phone!), I see you refer to a "memory breakpoint", by which I believe you mean that you are checking if a write occurs to a particular address at any point (we call these "watchpoints"). You are correct that a software implementation of these are terrible for performance, as the debugger has to check after every instruction whether or not that address was written to. You should be able to use DSTREAM in that manner to catch a write to a given address, by using the debugger command:

    awatch <address>

    (or in the memory window -> toggle watchpoint)

Children