mark2185 added a comment.

In D136465#3878581 <https://reviews.llvm.org/D136465#3878581>, @DavidSpickett 
wrote:

> Does this account for the situation where you spawn many gdbserver from the 
> platform and therefore need more ports? Does it even need to? (just guessing 
> that that could have been the reason for selecting random ports, though not 
> for the platform)

To be honest, I don't know. In all of my testing of practical use cases (i.e. 
launching an app and debugging it either through `CodeLLDB/vscode-lldb` or 
`Android Studio`), I've only ever seen two ports. One for the platform (when 
running `platform connect`), and one for `gdb` (when trying to `attach` to a 
`PID`).

`git blame` points to this <https://reviews.llvm.org/D12510>, as previously it 
was using the port specified when launching `lldb-server` for the `local` port, 
but it turns out it's better to have a random one and then forward it. And it 
makes sense, since the device you're trying to debug is //very likely// plugged 
into the same machine as you're running `ADB` on, which is perfect for 
//local// development.

But that wasn't good enough for the use case I have.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D136465/new/

https://reviews.llvm.org/D136465

_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to