Page MenuHomePhabricator

Improve performance when constructing custom fields for objects
ClosedPublic

Authored by epriestley on Jul 31 2016, 4:49 PM.
Tags
None
Referenced Files
F14063381: D16355.diff
Mon, Nov 18, 6:20 PM
F14057244: D16355.diff
Sun, Nov 17, 1:40 AM
F14050571: D16355.id39326.diff
Thu, Nov 14, 7:25 PM
F13997416: D16355.id.diff
Thu, Oct 24, 4:24 AM
F13990018: D16355.id39331.diff
Tue, Oct 22, 12:31 AM
Unknown Object (File)
Sep 15 2024, 9:48 AM
Unknown Object (File)
Sep 9 2024, 3:26 PM
Unknown Object (File)
Sep 3 2024, 9:13 PM
Subscribers
None

Details

Summary

Ref T11404. This improves things by about 10%:

  • Use PhutilClassMapQuery, which has slightly better caching.
  • Do a little less work to generate pretty error messages.
  • Make the "disabled" code a little faster (and sort of clearer, too?) by doing less fancy stuff.

These are pretty minor adjustments and not the sort of optimizations I'd make normally, but this code gets called ~100x (once per revision) and generates ~10 fields normally, so even small savings can amount to something.

(I also want to try to make arc faster in the next update, and improving Conduit performance helps with that.)

Test Plan

Ran differential.revision.search, saw cost drop from ~195ms to ~170ms locally.

Diff Detail

Repository
rP Phabricator
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

epriestley retitled this revision from to Improve performance when constructing custom fields for objects.
epriestley updated this object.
epriestley edited the test plan for this revision. (Show Details)
epriestley added reviewers: chad, yelirekim.
chad edited edge metadata.
This revision is now accepted and ready to land.Jul 31 2016, 5:04 PM
This revision was automatically updated to reflect the committed changes.