Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8217910

Slow linking with devkit on Linux

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P4
    • Resolution: Fixed
    • Affects Version/s: 13
    • Fix Version/s: 13
    • Component/s: infrastructure
    • Labels:
      None
    • Subcomponent:
    • Resolved In Build:
      b06
    • OS:
      linux

      Description

      While investigating performance with different linkers and linker configuration, we discovered that the devkit linker on Linux (both bfd and gold) were a lot slower than the native linker on Ubuntu. They are both the same version (2.30), so this was puzzling.

      The most obvious explanation for such a big difference would be missing compiler optimizations, but why would such a widely used product like binutils not have their compiler flags setup properly for optimization? But, looking at the build logs for binutils for Ubuntu: https://launchpad.net/ubuntu/+source/binutils/2.30-21ubuntu1~18.04/+build/15453713 they are setting CFLAGS="-O2" when running the build for binutils. I tried this for our devkit, and that created a kit with comparable linking performance to the Ubuntu linker.

      We should rebuild the current devkit for Linux with this setting to improve daily life for developers. While at it, I will also add --enable-threads which will make it possible for the adventurous to run the gold linker with threads from the devkit.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              erikj Erik Joelsson
              Reporter:
              erikj Erik Joelsson
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: