Skip to content

binary: Directly copy ShortByteString to buffer rather than go via ByteString

Matthew Pickering requested to merge wip/direct-sbs into master

This avoids allocating an intermediate bytestring. I just noticed on a profile that putFS was allocating, and it seemed strange to me why since it should just copy the contents of the FastString into the already allocated buffer. It turned out we were going indirectly via a ByteString.

Fixes #25861 (closed)

Merge request reports

Loading