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

(launcher) Adjust thresholds (disable) for server class machine detection

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P4
    • Resolution: Won't Fix
    • Affects Version/s: 6u10
    • Fix Version/s: None
    • Component/s: tools
    • Labels:
    • Subcomponent:
    • CPU:
      x86
    • OS:
      linux

      Description

      FULL PRODUCT VERSION :
      java version "1.6.0_10"
      Java(TM) SE Runtime Environment (build 1.6.0_10-b33)
      Java HotSpot(TM) Server VM (build 11.0-b15, mixed mode)


      ADDITIONAL OS VERSION INFORMATION :
      Linux localhost.localdomain 2.6.26.6-49.fc8 #1 SMP Fri Oct 17 15:59:36 EDT 2008 i686 i686 i386 GNU/Linux


      A DESCRIPTION OF THE PROBLEM :
      Since I upgraded my laptop from 1GB to 2GB ram, java based programs started up slow and user interface responsivness was not as good as before. Applet startup was suddenly very slow.
      Especially large java applications often took "think breaks" and Eclipse sometimes reporting that an operation took too long to complete and was canceled. Also java based applications suddenly used a lot more memory.

      I found out that this is caused by "server class machine detection", detecting that I am running java on a "server class machine" and automatically enabling the server runtime, which is suboptimal for graphical end-user applications because of slow startup, long compilation, higher memory footprint and missing class data sharing, as well as higher IO footprint at startup.
      When I forced java to use the client-compiler again, everything was back to normal speed, however it is quite complicated to force the client- compiler for all use-cases java is used.
      There's webstart, the plugin, java-standalone applications...

      My laptop is a typical desktop/laptop with a Core2Duo, and RAM is extremly cheap these days, even low-end systems are sold now with dual-core CPUs and 4GB of RAM. Even quad-core cpus are sold in cheap desktop systems.
      In my opinion server-class-machine detection is really flawed anyway, I hope tiered compilation will replace it for JDK7.

      However, until then would it be possible to adjust server-class-machine-detection thresholds to not detect even low-end systems as server-class machines, and maybe make server-class-machine-detection to work a bit better? Maybe it could check wether an XServer is running (very unlikely on real servers), or check wether the system contains server-class CPUs (like AMD Opteron instead of Phenom/Athlon and Intel Xeon instead of Pentium/Celeron/Core2Duo/Quads).

      STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
      Run large client applications (swing based) on a Linux system with 2GB ram or more.

      EXPECTED VERSUS ACTUAL BEHAVIOR :
      EXPECTED -
      at least perceived performance should not get worse
      ACTUAL -
      large performance drop for perceived performance

      REPRODUCIBILITY :
      This bug can be reproduced always.

      CUSTOMER SUBMITTED WORKAROUND :
      specify -client when starting, modify some properties files in the JRE, set the plugin to use the client-compiler switch.

        Attachments

          Activity

            People

            • Assignee:
              ksrini Kumar Srinivasan
              Reporter:
              ndcosta Nelson Dcosta
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                Imported:
                Indexed: