HomePhabricator

Add LCStore implementation that uses static arrays in PHP files

Authored by fred.
This commit no longer exists in the repository. It may have been part of a branch which was deleted.This commit has been deleted in the repository: it is no longer reachable from any branch, tag, or ref.

Description

Add LCStore implementation that uses static arrays in PHP files

Implementation written by Fred Emmott of Facebook. Quoting Fred:

As well as array access being faster, the main advantage is actually
that this significantly reduces the use of unserialize(), which does a
lot of memcpys when making the strings.

Benchmarks compared to LCStoreCDB:

  • HHVM (no repo-auth): ~7% improvement
  • HHVM (with repo-auth): ~12% improvement
  • PHP7: ~1% improvement

My (Legoktm) brief testing noted that the generated PHP files were
noticiably larger than the CDB ones:

  • 1.5M en.l10n.php
  • 932K l10n_cache-en.cdb

Bug: T99740
Change-Id: Ib2c5856d40cd928cab4a79cb935b3ce08c598300
(cherry picked from commit c403d4838dc8662d62902ced3713c1d9be6309cc)

Details

Committed
oriJun 11 2015, 8:45 PM
ChangeId
Ib2c5856d40cd928cab4a79cb935b3ce08c598300

Commit No Longer Exists

This commit no longer exists in the repository.