[all-commits] [llvm/llvm-project] 4b3633: [clangd] Reuse buffer for JSONTransport::sendMessage

Nathan James via All-commits all-commits at lists.llvm.org
Tue Dec 22 03:35:17 PST 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 4b3633cf2cb67220763494427f6db250bbd87494
      https://github.com/llvm/llvm-project/commit/4b3633cf2cb67220763494427f6db250bbd87494
  Author: Nathan James <n.james93 at hotmail.co.uk>
  Date:   2020-12-22 (Tue, 22 Dec 2020)

  Changed paths:
    M clang-tools-extra/clangd/JSONTransport.cpp

  Log Message:
  -----------
  [clangd] Reuse buffer for JSONTransport::sendMessage

Allocate a Buffer in the JSONTransport to be used when sending messages to the client.
This gets reused each time a message is sent, reducing in fewer malloc, which is always a bonus.

Reviewed By: sammccall

Differential Revision: https://reviews.llvm.org/D93531




More information about the All-commits mailing list