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

NewRatio ignored when UseConcMarkSweepGC set

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P4
    • Resolution: Duplicate
    • Affects Version/s: 6u14
    • Fix Version/s: None
    • Component/s: hotspot
    • Labels:
    • Subcomponent:
      gc
    • CPU:
      x86
    • OS:
      linux

      Description

      FULL PRODUCT VERSION :
      java version "1.6.0_14"
      Java(TM) SE Runtime Environment (build 1.6.0_14-b08)
      Java HotSpot(TM) 64-Bit Server VM (build 14.0-b16, mixed mode)


      FULL OS VERSION :
      Linux 2.6.20 #2 SMP x86_64 GNU/Linux
      SunOS 5.10 Generic_137111-07 sun4u sparc
      Darwin 9.8.0 Darwin Kernel Version 9.8.0 i386


      A DESCRIPTION OF THE PROBLEM :
      When using the attached command line to run any Java application, the size of New Generation should be set to 333MByte. It doesn't when UseConcMarkSweepGC is activated and sets to 166MByte only and does not scale with increased heap size. Without UseConcMarkSweepGC it sets correctly and scales with larger heap sizes.

      This bug makes deployment of large java applications to different systems difficult as memory settings have to be set manually. The setting of Xmx and Xms is controlled automatically by a well known external native Java Wrapper process.


      THE PROBLEM WAS REPRODUCIBLE WITH -Xint FLAG: Yes

      THE PROBLEM WAS REPRODUCIBLE WITH -server FLAG: Yes

      STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :

      java -Xmx1000m -Xms1000m -XX:NewRatio=2 -XX:SurvivorRatio=1 -XX:+UseConcMarkSweepGC -verbose:gc -XX:+PrintHeapAtGC -jar anyclasses.jar



      EXPECTED VERSUS ACTUAL BEHAVIOR :
      {Heap before GC invocations=1 (full 0):
       PSYoungGen total 682688K, used 341376K [0x00002aab30830000, 0x00002aab6f030000, 0x00002aab6f030000)
        eden space 341376K, 100% used [0x00002aab30830000,0x00002aab45590000,0x00002aab45590000)
        from space 341312K, 0% used [0x00002aab5a2e0000,0x00002aab5a2e0000,0x00002aab6f030000)
        to space 341312K, 0% used [0x00002aab45590000,0x00002aab45590000,0x00002aab5a2e0000)
       PSOldGen total 2048000K, used 0K [0x00002aaab3830000, 0x00002aab30830000, 0x00002aab30830000)
        object space 2048000K, 0% used [0x00002aaab3830000,0x00002aaab3830000,0x00002aab30830000)
       PSPermGen total 21248K, used 17529K [0x00002aaaae430000, 0x00002aaaaf8f0000, 0x00002aaab3830000)
        object space 21248K, 82% used [0x00002aaaae430000,0x00002aaaaf54e480,0x00002aaaaf8f0000)
      2009-08-12T17:15:51.755+0200: 4.468: [GC 341376K->35367K(2730688K), 0.0748970 secs]

      ERROR MESSAGES/STACK TRACES THAT OCCUR :
      actual result with Parallel-GC and exptected result with CMS-GC:

      {Heap before GC invocations=1 (full 0):
       PSYoungGen total 227584K, used 113856K [0x00002aaadd2e0000, 0x00002aaaf2030000, 0x00002aaaf2030000)
        eden space 113856K, 100% used [0x00002aaadd2e0000,0x00002aaae4210000,0x00002aaae4210000)
        from space 113728K, 0% used [0x00002aaaeb120000,0x00002aaaeb120000,0x00002aaaf2030000)
        to space 113728K, 0% used [0x00002aaae4210000,0x00002aaae4210000,0x00002aaaeb120000)
       PSOldGen total 682688K, used 0K [0x00002aaab3830000, 0x00002aaadd2e0000, 0x00002aaadd2e0000)
        object space 682688K, 0% used [0x00002aaab3830000,0x00002aaab3830000,0x00002aaadd2e0000)
       PSPermGen total 21248K, used 9636K [0x00002aaaae430000, 0x00002aaaaf8f0000, 0x00002aaab3830000)
        object space 21248K, 45% used [0x00002aaaae430000,0x00002aaaaed99000,0x00002aaaaf8f0000)
      2009-08-12T17:31:03.606+0200: 1.842: [GC 113856K->22176K(910272K), 0.0333530 secs]


      actual result with CMS-GC:

      {Heap before GC invocations=0 (full 0):
       par new generation total 113600K, used 56832K [0x00002aaaae430000, 0x00002aaab8a90000, 0x00002aaab8a90000)
        eden space 56832K, 100% used [0x00002aaaae430000, 0x00002aaab1bb0000, 0x00002aaab1bb0000)
        from space 56768K, 0% used [0x00002aaab1bb0000, 0x00002aaab1bb0000, 0x00002aaab5320000)
        to space 56768K, 0% used [0x00002aaab5320000, 0x00002aaab5320000, 0x00002aaab8a90000)
       concurrent mark-sweep generation total 853632K, used 0K [0x00002aaab8a90000, 0x00002aaaecc30000, 0x00002aaaecc30000)
       concurrent-mark-sweep perm gen total 21248K, used 9409K [0x00002aaaecc30000, 0x00002aaaee0f0000, 0x00002aaaf2030000)
      2009-08-12T17:31:33.842+0200: 1.572: [GC 56832K->10832K(967232K), 0.0278230 secs]


      REPRODUCIBILITY :
      This bug can be reproduced always.

      CUSTOMER SUBMITTED WORKAROUND :
      use -XX:NewSize=333m or -Xmn333m

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                ndcosta Nelson Dcosta (Inactive)
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Imported:
                  Indexed: