8005486: NPG: Incorrect assertion in ChunkManager::list_index()
authorjmasa
Wed, 26 Dec 2012 15:05:30 -0800
changeset 15087 8849ea877278
parent 15086 2bfd799e9147
child 15088 8875e774f1a3
8005486: NPG: Incorrect assertion in ChunkManager::list_index() Reviewed-by: coleenp
hotspot/src/share/vm/memory/metaspace.cpp
--- a/hotspot/src/share/vm/memory/metaspace.cpp	Mon Dec 03 15:09:39 2012 -0800
+++ b/hotspot/src/share/vm/memory/metaspace.cpp	Wed Dec 26 15:05:30 2012 -0800
@@ -2084,7 +2084,7 @@
     case ClassMediumChunk:
       return MediumIndex;
     default:
-      assert(size > MediumChunk && size > ClassMediumChunk,
+      assert(size > MediumChunk || size > ClassMediumChunk,
              "Not a humongous chunk");
       return HumongousIndex;
   }
@@ -2129,7 +2129,7 @@
     new_chunk->set_next(chunks_in_use(HumongousIndex));
     set_chunks_in_use(HumongousIndex, new_chunk);
 
-    assert(new_chunk->word_size() > MediumChunk, "List inconsistency");
+    assert(new_chunk->word_size() > medium_chunk_size(), "List inconsistency");
   }
 
   assert(new_chunk->is_empty(), "Not ready for reuse");