aboutsummaryrefslogtreecommitdiffhomepage
path: root/infra/bots/recipes/swarm_ct_skps.expected/CT_IMG_DECODE_10k_SKPs_Trybot.json
diff options
context:
space:
mode:
authorGravatar Bruce Dawson <brucedawson@google.com>2016-11-18 15:08:45 -0500
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2016-11-21 22:48:12 +0000
commit759ae5639b0dfe5a0d5491aa0e0b9855aa42ab73 (patch)
tree72cc24f11129c6f2420cefdf410296dfce2bd867 /infra/bots/recipes/swarm_ct_skps.expected/CT_IMG_DECODE_10k_SKPs_Trybot.json
parentc59034145862bf6dc0c503cb1e47eecd321ffa8c (diff)
Avoid runtime initialization of FLT_EPSILON_SQRT
FLT_EPSILON_SQRT is initialized with a call to sqrt which, in release builds on Windows, results in an initializer call (on official release builds this is optimized away). On Windows release (all flavors) builds this also triggers duplicate instantiations of the variable (always a risk with non-integral const variables defined in header files) with 32 copies ending up in both chrome.dll and chrome_child.dll. This change avoids the run-time initializer and as a side effect it also avoids most or all of the duplication. Section size savings in a Windows 32-bit release official build are: chrome.dll .text: -64 bytes change .rdata: -16 bytes change .data: -256 bytes change .reloc: -116 bytes change Total change: -452 bytes chrome_child.dll .text: 160 bytes change .rdata: -144 bytes change .data: -256 bytes change .reloc: -60 bytes change Total change: -300 bytes A more complete fix would include using extern const to declare these constants in the header file but define them once in a .cc file, but it's not clear that this is necessary. The size savings on non-official builds are greater. The increase in the .text segment is odd, but harmless since those bytes are shared. BUG=630755 GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=5061 Change-Id: I53d0cdc38e022039646df491d824a1aaf11def80 Reviewed-on: https://skia-review.googlesource.com/5061 Reviewed-by: Cary Clark <caryclark@google.com> Reviewed-by: Bruce Dawson <brucedawson@google.com> Commit-Queue: Cary Clark <caryclark@google.com>
Diffstat (limited to 'infra/bots/recipes/swarm_ct_skps.expected/CT_IMG_DECODE_10k_SKPs_Trybot.json')
0 files changed, 0 insertions, 0 deletions