Author: jmolenda Date: Thu Dec 6 16:35:26 2018 New Revision: 348557 URL: http://llvm.org/viewvc/llvm-project?rev=348557&view=rev Log: Change the amount of data that Platform::PutFile will try to transfer in one packet from 1k bytes to 16k bytes. Sending a large file to an iOS device directly connected by USB cable, to lldb-server running in platform mode, this speeds up the file xfer by 77%. Sending the file in 32k blocks speeds up the file xfer by 80% versus 1k blocks, starting with 16k to make sure we don't have any problems with android testing.
We may not have the same perf characteristics over ethernet, but with USB it's faster to send fewer larger packets than many small packets. Modified: lldb/trunk/source/Target/Platform.cpp Modified: lldb/trunk/source/Target/Platform.cpp URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Target/Platform.cpp?rev=348557&r1=348556&r2=348557&view=diff ============================================================================== --- lldb/trunk/source/Target/Platform.cpp (original) +++ lldb/trunk/source/Target/Platform.cpp Thu Dec 6 16:35:26 2018 @@ -1296,7 +1296,7 @@ Status Platform::PutFile(const FileSpec return error; if (dest_file == UINT64_MAX) return Status("unable to open target file"); - lldb::DataBufferSP buffer_sp(new DataBufferHeap(1024, 0)); + lldb::DataBufferSP buffer_sp(new DataBufferHeap(1024 * 16, 0)); uint64_t offset = 0; for (;;) { size_t bytes_read = buffer_sp->GetByteSize(); _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits