RFR: 8304893: Link Time Optimization with gcc can be faster

Julian Waters jwaters at openjdk.org
Fri Mar 24 17:28:13 UTC 2023


A previous argument against link time optimization support that we have for gcc is that it was extremely slow. After some checks it turns out we are passing rather inefficient flags to gcc in optimized builds. Changing these flags to run the linker optimizations in parallel and passing additional flags to the compiler have the ability to speed this process up significantly. Also fixes some incorrect flags passed to ld for linking as well

-------------

Commit messages:
 - JvmFeatures.gmk
 - autoconf

Changes: https://git.openjdk.org/jdk/pull/13180/files
 Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=13180&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8304893
  Stats: 8 lines in 2 files changed: 5 ins; 0 del; 3 mod
  Patch: https://git.openjdk.org/jdk/pull/13180.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/13180/head:pull/13180

PR: https://git.openjdk.org/jdk/pull/13180



More information about the build-dev mailing list