|
|
Created:
4 years, 1 month ago by brucedawson Modified:
4 years, 1 month ago Reviewers:
scottmg CC:
chromium-reviews Target Ref:
refs/pending/heads/master Project:
chromium Visibility:
Public. |
DescriptionMake /fastlink builds as optimized as non-/fastlink builds
The /DEBUG:FASTLINK flag is incompatible with /PROFILE, so we turn off
/PROFILE when using /DEBUG:FASTLINK. However /PROFILE turns on various
linker optimization, which means that /DEBUG:FASTLINK results in larger
binaries, for no good reason. This was causing some confusion when
working on size optimizations. This change ensures that when /PROFILE is
turned off due to /DEBUG:FASTLINK that the same linker optimization
flags are applied.
This has no effect on non-fastlink builds, it just ensures that
is_win_fastlink does not affect binary sizes. Link times (measured for
non-component 64-bit release chrome.dll and chrome_child.dll) are about
2.7 faster with fastlink than without with this change, which is inline
with before.
This change also avoids using /debug:fastlink on minimal_symbols builds.
On such builds (because there is no debug information in the .obj files
or shared .pdb files) fastlink has no value and actually makes the final
PDBs slightly *bigger*.
BUG=495670
Committed: https://crrev.com/b05140cde29b38d482e1201b77fcf68fd310daa7
Cr-Commit-Position: refs/heads/master@{#431985}
Patch Set 1 #Patch Set 2 : Don't enable fastlink on minimal_symbols builds #
Total comments: 3
Patch Set 3 : Fix is_syzyasan logic per code review comments #
Messages
Total messages: 22 (14 generated)
Description was changed from ========== Make /fastlink builds as optimized as non-/fastlink builds The /DEBUG:FASTLINK flag is incompatible with /PROFILE, so we turn off /PROFILE when using /DEBUG:FASTLINK. However /PROFILE turns on various linker optimization, which means that /DEBUG:FASTLINK results in larger binaries, for no good reason. This was causing some confusion when working on size optimizations. This change ensures that when /PROFILE is turned off due to /DEBUG:FASTLINK that the same linker optimization flags are applied. This has no effect on non-fastlink builds, it just ensures that is_win_fastlink does not affect binary sizes. Link times (measured for non-component 64-bit release chrome.dll and chrome_child.dll) are about 2.7 faster with fastlink than without with this change, which is inline with before. BUG=495670 ========== to ========== Make /fastlink builds as optimized as non-/fastlink builds The /DEBUG:FASTLINK flag is incompatible with /PROFILE, so we turn off /PROFILE when using /DEBUG:FASTLINK. However /PROFILE turns on various linker optimization, which means that /DEBUG:FASTLINK results in larger binaries, for no good reason. This was causing some confusion when working on size optimizations. This change ensures that when /PROFILE is turned off due to /DEBUG:FASTLINK that the same linker optimization flags are applied. This has no effect on non-fastlink builds, it just ensures that is_win_fastlink does not affect binary sizes. Link times (measured for non-component 64-bit release chrome.dll and chrome_child.dll) are about 2.7 faster with fastlink than without with this change, which is inline with before. This change also avoids using /debug:fastlink on minimal_symbols builds. On such builds (because there is no debug information in the vc140.pdb or .obj files) fastlink has no value and actually makes the final PDBs *bigger*. BUG=495670 ==========
The CQ bit was checked by brucedawson@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: This issue passed the CQ dry run.
brucedawson@chromium.org changed reviewers: + scottmg@chromium.org
https://codereview.chromium.org/2495643002/diff/20001/build/config/win/BUILD.gn File build/config/win/BUILD.gn (right): https://codereview.chromium.org/2495643002/diff/20001/build/config/win/BUILD.... build/config/win/BUILD.gn:96: if (is_win_fastlink) { I think this changes the behaviour for is_syzyasan with is_win_fastlink. I don't think we need to support that combinations, but maybe it would be clearer to just move the is_syzyasan to a separate if that always sets /PROFILE and assert(!is_fastlink), and make a second that sets the linker opt flags that doesn't consider is_syzyasan at all.
https://codereview.chromium.org/2495643002/diff/20001/build/config/win/BUILD.gn File build/config/win/BUILD.gn (right): https://codereview.chromium.org/2495643002/diff/20001/build/config/win/BUILD.... build/config/win/BUILD.gn:96: if (is_win_fastlink) { On 2016/11/10 21:56:27, scottmg (ooo nov11) wrote: > I think this changes the behaviour for is_syzyasan with is_win_fastlink. > > I don't think we need to support that combinations, but maybe it would be > clearer to just move the is_syzyasan to a separate if that always sets /PROFILE > and assert(!is_fastlink), and make a second that sets the linker opt flags that > doesn't consider is_syzyasan at all. Good catch. Logic is hard. Agreed that it probably doesn't matter but we should maintain existing logic.
The CQ bit was checked by brucedawson@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
Description was changed from ========== Make /fastlink builds as optimized as non-/fastlink builds The /DEBUG:FASTLINK flag is incompatible with /PROFILE, so we turn off /PROFILE when using /DEBUG:FASTLINK. However /PROFILE turns on various linker optimization, which means that /DEBUG:FASTLINK results in larger binaries, for no good reason. This was causing some confusion when working on size optimizations. This change ensures that when /PROFILE is turned off due to /DEBUG:FASTLINK that the same linker optimization flags are applied. This has no effect on non-fastlink builds, it just ensures that is_win_fastlink does not affect binary sizes. Link times (measured for non-component 64-bit release chrome.dll and chrome_child.dll) are about 2.7 faster with fastlink than without with this change, which is inline with before. This change also avoids using /debug:fastlink on minimal_symbols builds. On such builds (because there is no debug information in the vc140.pdb or .obj files) fastlink has no value and actually makes the final PDBs *bigger*. BUG=495670 ========== to ========== Make /fastlink builds as optimized as non-/fastlink builds The /DEBUG:FASTLINK flag is incompatible with /PROFILE, so we turn off /PROFILE when using /DEBUG:FASTLINK. However /PROFILE turns on various linker optimization, which means that /DEBUG:FASTLINK results in larger binaries, for no good reason. This was causing some confusion when working on size optimizations. This change ensures that when /PROFILE is turned off due to /DEBUG:FASTLINK that the same linker optimization flags are applied. This has no effect on non-fastlink builds, it just ensures that is_win_fastlink does not affect binary sizes. Link times (measured for non-component 64-bit release chrome.dll and chrome_child.dll) are about 2.7 faster with fastlink than without with this change, which is inline with before. This change also avoids using /debug:fastlink on minimal_symbols builds. On such builds (because there is no debug information in the .obj files or shared .pdb files) fastlink has no value and actually makes the final PDBs slightly *bigger*. BUG=495670 ==========
Okay, should be good now. Now this change should only affect is_win_fastlink builds, as designed. https://codereview.chromium.org/2495643002/diff/20001/build/config/win/BUILD.gn File build/config/win/BUILD.gn (right): https://codereview.chromium.org/2495643002/diff/20001/build/config/win/BUILD.... build/config/win/BUILD.gn:96: if (is_win_fastlink) { On 2016/11/10 22:04:06, brucedawson wrote: > On 2016/11/10 21:56:27, scottmg (ooo nov11) wrote: > > I think this changes the behaviour for is_syzyasan with is_win_fastlink. > > > > I don't think we need to support that combinations, but maybe it would be > > clearer to just move the is_syzyasan to a separate if that always sets > /PROFILE > > and assert(!is_fastlink), and make a second that sets the linker opt flags > that > > doesn't consider is_syzyasan at all. > > Good catch. Logic is hard. Agreed that it probably doesn't matter but we should > maintain existing logic. Done.
lgtm
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: This issue passed the CQ dry run.
The CQ bit was checked by brucedawson@chromium.org
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
Message was sent while issue was closed.
Description was changed from ========== Make /fastlink builds as optimized as non-/fastlink builds The /DEBUG:FASTLINK flag is incompatible with /PROFILE, so we turn off /PROFILE when using /DEBUG:FASTLINK. However /PROFILE turns on various linker optimization, which means that /DEBUG:FASTLINK results in larger binaries, for no good reason. This was causing some confusion when working on size optimizations. This change ensures that when /PROFILE is turned off due to /DEBUG:FASTLINK that the same linker optimization flags are applied. This has no effect on non-fastlink builds, it just ensures that is_win_fastlink does not affect binary sizes. Link times (measured for non-component 64-bit release chrome.dll and chrome_child.dll) are about 2.7 faster with fastlink than without with this change, which is inline with before. This change also avoids using /debug:fastlink on minimal_symbols builds. On such builds (because there is no debug information in the .obj files or shared .pdb files) fastlink has no value and actually makes the final PDBs slightly *bigger*. BUG=495670 ========== to ========== Make /fastlink builds as optimized as non-/fastlink builds The /DEBUG:FASTLINK flag is incompatible with /PROFILE, so we turn off /PROFILE when using /DEBUG:FASTLINK. However /PROFILE turns on various linker optimization, which means that /DEBUG:FASTLINK results in larger binaries, for no good reason. This was causing some confusion when working on size optimizations. This change ensures that when /PROFILE is turned off due to /DEBUG:FASTLINK that the same linker optimization flags are applied. This has no effect on non-fastlink builds, it just ensures that is_win_fastlink does not affect binary sizes. Link times (measured for non-component 64-bit release chrome.dll and chrome_child.dll) are about 2.7 faster with fastlink than without with this change, which is inline with before. This change also avoids using /debug:fastlink on minimal_symbols builds. On such builds (because there is no debug information in the .obj files or shared .pdb files) fastlink has no value and actually makes the final PDBs slightly *bigger*. BUG=495670 ==========
Message was sent while issue was closed.
Committed patchset #3 (id:40001)
Message was sent while issue was closed.
Description was changed from ========== Make /fastlink builds as optimized as non-/fastlink builds The /DEBUG:FASTLINK flag is incompatible with /PROFILE, so we turn off /PROFILE when using /DEBUG:FASTLINK. However /PROFILE turns on various linker optimization, which means that /DEBUG:FASTLINK results in larger binaries, for no good reason. This was causing some confusion when working on size optimizations. This change ensures that when /PROFILE is turned off due to /DEBUG:FASTLINK that the same linker optimization flags are applied. This has no effect on non-fastlink builds, it just ensures that is_win_fastlink does not affect binary sizes. Link times (measured for non-component 64-bit release chrome.dll and chrome_child.dll) are about 2.7 faster with fastlink than without with this change, which is inline with before. This change also avoids using /debug:fastlink on minimal_symbols builds. On such builds (because there is no debug information in the .obj files or shared .pdb files) fastlink has no value and actually makes the final PDBs slightly *bigger*. BUG=495670 ========== to ========== Make /fastlink builds as optimized as non-/fastlink builds The /DEBUG:FASTLINK flag is incompatible with /PROFILE, so we turn off /PROFILE when using /DEBUG:FASTLINK. However /PROFILE turns on various linker optimization, which means that /DEBUG:FASTLINK results in larger binaries, for no good reason. This was causing some confusion when working on size optimizations. This change ensures that when /PROFILE is turned off due to /DEBUG:FASTLINK that the same linker optimization flags are applied. This has no effect on non-fastlink builds, it just ensures that is_win_fastlink does not affect binary sizes. Link times (measured for non-component 64-bit release chrome.dll and chrome_child.dll) are about 2.7 faster with fastlink than without with this change, which is inline with before. This change also avoids using /debug:fastlink on minimal_symbols builds. On such builds (because there is no debug information in the .obj files or shared .pdb files) fastlink has no value and actually makes the final PDBs slightly *bigger*. BUG=495670 Committed: https://crrev.com/b05140cde29b38d482e1201b77fcf68fd310daa7 Cr-Commit-Position: refs/heads/master@{#431985} ==========
Message was sent while issue was closed.
Patchset 3 (id:??) landed as https://crrev.com/b05140cde29b38d482e1201b77fcf68fd310daa7 Cr-Commit-Position: refs/heads/master@{#431985} |