[PATCH] D30363: COFF ICF: Merge only functions. Do not merge read-only data.

Peter Collingbourne via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Feb 27 14:15:44 PST 2017


pcc added a comment.

In https://reviews.llvm.org/D30363#687836, @ruiu wrote:

> > Maybe, but I'd slightly prefer to encode the information in the object files rather than introducing another flag.
> > 
> > Although it looks like Chromium Windows builds are already using /OPT:REF and /OPT:ICF:
> >  https://cs.chromium.org/chromium/src/build/config/win/BUILD.gn?type=cs&q=%22opt:icf%22&sq=package:chromium&l=102
> >  (but only when building with Clang or fastlink because /PROFILE implies /OPT:NOICF contrary to what the comment says (!))
> > 
> > So now I'm confused as to how we were running into problems before.
>
> Me too. If the MSVC linker behaves as described by the text that David pasted, the LLD'd behavior is not new to Chrome, so it shouldn't have caused an issue.


Reid, I think you mentioned that you saw this problem only with LLD, do you have any more details?


https://reviews.llvm.org/D30363





More information about the llvm-commits mailing list