[all-commits] [llvm/llvm-project] 7ebcd8: Add DumpBinaryEscaped method to JSONGenerator, avo...

Jason Molenda via All-commits all-commits at lists.llvm.org
Mon Apr 4 14:14:17 PDT 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 7ebcd8891a7acc265cee4996d55a287a035f8771
      https://github.com/llvm/llvm-project/commit/7ebcd8891a7acc265cee4996d55a287a035f8771
  Author: Jason Molenda <jason at molenda.com>
  Date:   2022-04-04 (Mon, 04 Apr 2022)

  Changed paths:
    M lldb/tools/debugserver/source/JSONGenerator.h
    M lldb/tools/debugserver/source/RNBRemote.cpp

  Log Message:
  -----------
  Add DumpBinaryEscaped method to JSONGenerator, avoid extra copy

All uses of JSONGenerator in debugserver would create a JSON text
dump of the object collection, then copy that string into a
binary-escaped string, then send it up to the lldb side or
make a compressed version and send that.

This adds a DumpBinaryEscaped method to JSONGenerator which
does the gdb remote serial protocol binary escaping directly,
and removes the need to pass over the string and have an
additional copy in memory.

Differential Revision: https://reviews.llvm.org/D122882
rdar://91117456




More information about the All-commits mailing list