Peformance with "-O3 -flto" is worse than "-O3" (without -flto)

XMLWordPrintable

    • Type: Bug
    • Resolution: Fixed
    • Priority: Medium
    • Code Generation Tools
    • CODEGEN-15063
    • Hide
      ARMCLANG_4.0.0.LTS
      ARMCLANG_3.2.0.LTS
      C29_2.2.0.LTS
      Show
      ARMCLANG_4.0.0.LTS ARMCLANG_3.2.0.LTS C29_2.2.0.LTS
    • C29_2.2.0.LTS
    • default

      A linker issue causes code recompiled as part of link-time optimization to always use the "-O2" level of optimization. This means that when combined with -flto, code compiled with -O0 or -O1 may be faster, larger, and harder to debug. It also means that code compiled with -O3 may be significantly slower than expected when using link-time optimization.

      As a workaround, affected programs may want to disable -flto entirely.

      For performance-focused programs, excluding certain files from recompilation by not using -flto for those specific files may serve as an additional workaround.

            Assignee:
            TI User
            Reporter:
            TI User
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

                Connection: Intermediate to External PROD System
                EXTSYNC-6388 - Peformance with "-O3 -flto" is wors...
                SYNCHRONIZED
                • Last Sync Date: