commit | a642f81bd7da2c6b02bd288c443c8e42416baa58 | [log] [tgz] |
---|---|---|
author | sashab <sashab@chromium.org> | Mon Dec 12 03:17:49 2016 |
committer | Commit bot <commit-bot@chromium.org> | Mon Dec 12 03:20:43 2016 |
tree | 5f09c2b4a476c20b42a3a15ac31da89d1cbd3022 | |
parent | a3533cd71ad51ad93a34bfed5bf1762ef936f411 [diff] |
Sort fields in ComputedStyleBase in decreasing order of size Sort fields in ComputedStyleBase in decreasing order of size. This is a micro optimization that improves field alignment and minimizes wasted memory space. From Intel on 'Coding for Performance': https://software.intel.com/en-us/articles/coding-for-performance-data-alignment-and-structures "One can try to minimize this memory wastage by ordering the structure elements such that the widest (largest) element comes first, followed by the second widest, and so on." Another good explanation article: https://msdn.microsoft.com/en-us/library/ewwyfdbe.aspx BUG=628043 Review-Url: https://codereview.chromium.org/2558733002 Cr-Commit-Position: refs/heads/master@{#437813}