Optimize away IOBuf clones on hot path
authorJon Maltiel Swenson <jmswen@fb.com>
Wed, 27 Apr 2016 01:12:20 +0000 (18:12 -0700)
committerFacebook Github Bot 5 <facebook-github-bot-5-bot@fb.com>
Wed, 27 Apr 2016 01:20:24 +0000 (18:20 -0700)
commit4aa901d0f9198b17c23adce704d18d767c033533
treeddf75c5c6cc26ba675104a96439bc6a09fb9caf3
parent545134d11e72181e9df4bdcbd17ba6ccc8196c07
Optimize away IOBuf clones on hot path

Summary:
'get' is the most frequent memcached operation. On a get reply, we should go to heap
as little as possible.  This diff optimizes for this scenario, where replies
have only one IOBuf field.

Reviewed By: pavlo-fb

Differential Revision: D3226592

fb-gh-sync-id: 92e1a1fac5735bd268691cf11990a96ae6fa8309
fbshipit-source-id: 92e1a1fac5735bd268691cf11990a96ae6fa8309
folly/io/Cursor.h