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

HotSpot Virtual Machine Error, assertion failure

XMLWordPrintable

    • x86
    • windows_nt



      Name: szC45993 Date: 03/24/99



      The Tonga/src/nsk/arguments/args00133 test uses big amount of integer
      debugging flags (received from default set for 10alpha1 hs jvm).
      It leads to Machine Error instead of normal exit.

      $ c:/jdk1.2.ZSS02/bin/java_g -version
      java version "1.2"
      HotSpot VM (1.0rc2, mixed mode, debug build C)
      [Verifying threads permgen oldgen ct newgen rset syms lkup zone dict hand C-heap ]
      $ c:/Jdk1.2.ZSS02/bin/java_g -XX":"Flags=f:/ld24/java/Tonga/testbase\src\nsk\arguments\args00133\opts -verify args00133
      ...
      #
      # HotSpot Virtual Machine Error, assertion failure
      #
      # assert(reserved_size >= committed_size, "reserved size must be >= committed size")
      # D:/localbuilds/hotspot_rc2_hp\src\share\vm\memory\heap.cpp, 117#


      Options set (opts file contents):
      =================================

      NmethodSweepFraction=16
      NMethodSweepInterval=1000
      MemProfilingInterval=500
      PostMortemDump=1
      AssertRepeat=1
      HandleAllocationLimit=1024
      TotalHandleAllocationLimit=1024
      StackPrintLimit=100
      MaxElementPrintSize=256
      MaxSubklassPrintSize=4
      MaxInlineLevel=5
      MaxInlineSize=12
      MaxTrivialSize=6
      MaxBackPatches=3
      AlignEntryCode=4
      CodeBufferSize=64*K
      MaxNMethodSize=8*K
      MethodHistogramCutoff=100
      ProfilerNumberOfInterpretedMethods=25
      ProfilerNumberOfCompiledMethods=25
      ProfilerNumberOfStubMethods=25
      ICacheAlignmentMode=0
      ScavengeALotInterval=1
      DontYieldALotInterval=10
      EventLogLength=2000
      ProfilerPCTickThreshold=15
      DeoptimizeALotInterval=5
      MallocVerifyInterval=0
      MallocVerifyStart=0
      # /* code cache parameters */
      CodeCacheSegmentSize=64
      CodeEntryAlignment=32
      InitialCodeCacheSize=160
      ReservedCodeCacheSize=32*K
      CodeCacheExpansionSize=32
      # /* interpreter debugging */
      BinarySwitchThreshold=5
      StopInterpreterAt=0
      TraceBytecodesAt=0
      # /* recompilation */
      CompileThreshold=1000
      MaxRecompilationSearchLength=10
      MaxInterpretedSearchLength=3
      HugeMethodLimit=5000
      # /* recompilation monitoring / throttling (most values read only at startup)*/
      RecompilationMonitorIntervalLength=200
      RecompilationMonitorIntervals=5
      CompilationPercentageThresholdHigh=20
      CompilationPercentageThresholdLow=5
      InterpreterOverheadThresholdHigh=15
      InterpreterOverheadThresholdLow=5
      CompileThresholdMin=500
      CompileThresholdMax=50000
      CompileThresholdAdjustFactor=150
      CounterHalfLifeTime=30
      # /* Bytecode optimization */
      OptoStart=0
      OptoStop=-1
      ThreadStackSize=0


      SOURCE:
      ========

      //--------------------- args00133.java:
      //args00133.java
      /* This test simply creates a series of circularly
       * linked memeory objects which should be able to be
       * GC'd
       */


      class MemoryObject
      {
          byte array[];
          MemoryObject next;
          MemoryObject previous;

          public MemoryObject(int size)
          {
              array = new byte[size];
          }
      }

      class args00133
      {
          static final int ARRAY_SIZE = 100;
          static final int OBJECT_SIZE = 10;
          static final int LOOP_COUNT = 5;
          static final int CIRCULARITY_SIZE = 3;

          static MemoryObject memoryArray[] = new MemoryObject[ARRAY_SIZE];

          public static void main(String args[])
          {
              for (int j = 0; j < LOOP_COUNT; j++)
              {
                  System.out.println(j + ": " + Runtime.getRuntime().freeMemory());
                  for (int i = 0; i < ARRAY_SIZE; i ++)
                  {
                      memoryArray[i] = new MemoryObject(OBJECT_SIZE);
                      makeCircular(memoryArray[i], CIRCULARITY_SIZE);
                  }
              }

              // if there's any memory left, let's assume it's okay
              System.out.println("Test passed.");

          }

          public static void makeCircular(MemoryObject mObj, int depth)
          {
      MemoryObject tmpObj = mObj;

              for (int i = 0; i < depth; i++)
              {
                  tmpObj.next = new MemoryObject(OBJECT_SIZE);
                  tmpObj= tmpObj.next;
              }
      tmpObj.next = mObj;
          }

          public static void confirmCircular(MemoryObject mObj)
          {
      int count = 0;
      MemoryObject mObj2 = mObj;
      while (mObj2.next != mObj)
      {
      count++;
      mObj2 = mObj2.next;
      }
      System.out.println("Circularity level: " + count);
          }
      }
      //---------------------

      ======================================================================

            rschmidtsunw Rene Schmidt (Inactive)
            zsssunw Zss Zss (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: