Improve performance of fbstring copy and move ctors on small strings
authorGiuseppe Ottaviano <ott@fb.com>
Mon, 5 Oct 2015 04:22:12 +0000 (21:22 -0700)
committerfacebook-github-bot-9 <folly-bot@fb.com>
Mon, 5 Oct 2015 05:20:22 +0000 (22:20 -0700)
commitf63b080574f6a139c952fe2a0c06f16fdf170042
tree6b02070254bae9012b7ccd4e42a8d68e3d32cf64
parent1638d60d9e50a131a122a53abdf2ce060634c59a
Improve performance of fbstring copy and move ctors on small strings

Summary: The move constructor of `fbstring` generates a large amount of code, preventing it to be inlined, and it is inefficient for small strings. This diff fixes both problems.

Reviewed By: @yfeldblum

Differential Revision: D2505762
folly/FBString.h