Using TCP sockets is insecure against local attackers, and possibly against remote attackers too (some vulnerabilities may allow tricking a browser to make a request to localhost). Use socketpair (which is immune to such attacks) on all Unix platforms.
Looks fine to me, lets make sure Pavel is OK with this. On MacOS socketpair is also much faster. Please run the following command while stopped at a breakpoint with and without your change:
(lldb) process plugin packet speed-test
It will send and receive packets using a variety of sizes and report the number of packets per second.
Have you tried that this actually works? (It doesn't work for me)
As far as I can tell, you will have to teach lldb-server to understand the --fd argument before you can flip this switch.
This is completely wrong. The --pipe argument is used to write the port that lldb-server listens on. Making --fd an alias to that will not help.
Please make sure you test your change before submitting it for review. You should at least make sure you are able to debug a hello world program with your modifications.
LGTM. Test run on Linux is clear. I also see a bit of perf bump.
Before checking in please remove outdated comment from ProcessGDBRemote::LaunchAndConnectToDebugserver.
// Use a socketpair on Apple for now until other platforms can verify it // works and is fast enough
Pavel & Eugene haven't marked it accepted yet, but from the comments is looks like they are both okay with the change. So it looks to me like everything is done but checking the code in.
If you have checkin privileges, then just check it in and as Greg says keep an eye on the bots. If you don't then speak up and one of us will check it in for you.