Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-108719

[MSVC] Improve the LTCG build

    XMLWordPrintable

Details

    • Suggestion
    • Resolution: Fixed
    • P3: Somewhat important
    • 6.5.0
    • None
    • Build System: CMake
    • None
    • Windows
    • 0d708a9aa (dev)

    Description

      Currently if we enable LTCG, it will be enabled globally for all CMake targets. On Windows Qt will use the bundled 3rd party libraries, which will always be built as static libraries, and enabling LTCG for them will produce very large output, usually greater than 100MB per file. If we are building static Qt, it's fine because we don't have any dlls and the .lib files are all very large (that's exptected), but for shared Qt, it's not good, it makes the Qt package way too large than normal builds. Maybe we can optimize this.

      NOTE: Only happens on MSVC. clang (clang-cl and clang-mingw) and gcc-mingw won't produce such big static library even if LTO is enabled.

      Attachments

        For Gerrit Dashboard: QTBUG-108719
        # Subject Branch Project Status CR V

        Activity

          People

            qtbuildsystem Qt Build System Team
            wangwenx190 赵 宇航
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes