Don't construct a new String/StringData for apc_unserialize
commit0ac0cf5564192a3b1f8eb7ce0f916e5be6937778
authormwilliams <mwilliams@fb.com>
Mon, 12 Aug 2013 17:57:33 +0000 (12 10:57 -0700)
committerSara Golemon <sgolemon@fb.com>
Tue, 13 Aug 2013 21:24:26 +0000 (13 14:24 -0700)
tree346d723203e6342f800a13c3138807d62741c33b
parent35144c5398688cf2fc6f7a3f45e448f042ca6051
Don't construct a new String/StringData for apc_unserialize

Every callsite of apc_unserialize constructed a String from a char*
and a length (involving at least one smart allocation, and a copy of the
data), passed it into apc_unserialize, which then extracted the char*
and length.

Just deal with the char*/length instead.

Differential Revision: D924015
hphp/runtime/base/concurrent-shared-store.cpp
hphp/runtime/base/shared-variant.cpp
hphp/runtime/ext/ext_apc.cpp
hphp/runtime/ext/ext_apc.h