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

Rendering images from PDF files slower in OpenJDK

    Details

    • Subcomponent:
      2d
    • Introduced In Version:
      9
    • CPU:
      x86_64
    • OS:
      linux_ubuntu

      Description

      ADDITIONAL SYSTEM INFORMATION :
      Gentoo Linux
      openjdk version "11" 2018-09-25
      OpenJDK Runtime Environment 18.9 (build 11+28)
      OpenJDK 64-Bit Server VM 18.9 (build 11+28, mixed mode)


      A DESCRIPTION OF THE PROBLEM :
      We render a lot of images with PDFBox with Java 1.8.0 and we want to upgrade to the current OpenJDK 11 but sadly we see some performance degradation switching over to OpenJDK. Anyone have a suggestion to remedy this issue, or can explain why it is slower?

      Using the PDFBox app current release downloadable from
      http://www-us.apache.org/dist/pdfbox/2.0.11/pdfbox-app-2.0.11.jar

      Running the command
      java -jar pdfbox-app-2.0.11.jar PDFToImage -time test.pdf

      We see the following result

      ---------------------------------------------------------
      java version "1.8.0_181"
      Java(TM) SE Runtime Environment (build 1.8.0_181-b13)
      Java HotSpot(TM) 64-Bit Server VM (build 25.181-b13, mixed mode)
      Rendered 1 page in 2762ms
      ---------------------------------------------------------
      openjdk version "9.0.4"
      OpenJDK Runtime Environment (build 9.0.4+11)
      OpenJDK 64-Bit Server VM (build 9.0.4+11, mixed mode)
      Rendered 1 page in 8034ms
      ---------------------------------------------------------
      openjdk version "10.0.2" 2018-07-17
      OpenJDK Runtime Environment 18.3 (build 10.0.2+13)
      OpenJDK 64-Bit Server VM 18.3 (build 10.0.2+13, mixed mode)
      Rendered 1 page in 4255ms
      ---------------------------------------------------------
      openjdk version "11" 2018-09-25
      OpenJDK Runtime Environment 18.9 (build 11+28)
      OpenJDK 64-Bit Server VM 18.9 (build 11+28, mixed mode)
      Rendered 1 page in 4275ms
      ---------------------------------------------------------
      openjdk version "12-ea" 2019-03-19
      OpenJDK Runtime Environment 19.3 (build 12-ea+11)
      OpenJDK 64-Bit Server VM 19.3 (build 12-ea+11, mixed mode)
      Rendered 1 page in 4399ms

      The pdf file used in this example can be downloaded from
      https://drive.google.com/file/d/139wP6PDmmQ6KBTyeJTETIrplSuOUgFfG/view?usp=sharing

      REGRESSION : Last worked in version 8u172

      STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
      1. Download http://www-us.apache.org/dist/pdfbox/2.0.11/pdfbox-app-2.0.11.jar
      2. Download https://drive.google.com/file/d/139wP6PDmmQ6KBTyeJTETIrplSuOUgFfG/view?usp=sharing
      3. Run java -jar pdfbox-app-2.0.11.jar PDFToImage -time test.pdf

      EXPECTED VERSUS ACTUAL BEHAVIOR :
      EXPECTED -
      Same or better speed in newer releases of OpenJDK
      ACTUAL -
      OpenJDK takes 4x more time to render and OpenJDK 11 takes 2x more time.

      ---------- BEGIN SOURCE ----------
      https://github.com/apache/pdfbox
      ---------- END SOURCE ----------

      CUSTOMER SUBMITTED WORKAROUND :
      Don't upgrade

      FREQUENCY : always


        Attachments

          Activity

            People

            • Assignee:
              prr Philip Race
              Reporter:
              webbuggrp Webbug Group
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated: