src/hotspot/share/memory/binaryTreeDictionary.inline.hpp
changeset 52767 db7a459e10eb
parent 50193 49c3e91c424f
child 53244 9807daeb47c4
--- a/src/hotspot/share/memory/binaryTreeDictionary.inline.hpp	Thu Nov 29 10:13:42 2018 -0800
+++ b/src/hotspot/share/memory/binaryTreeDictionary.inline.hpp	Thu Nov 29 13:04:25 2018 -0500
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2001, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2001, 2018, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -229,7 +229,8 @@
   assert(chunk->list() == this, "list should be set for chunk");
   assert(tail() != NULL, "The tree list is embedded in the first chunk");
   // which means that the list can never be empty.
-  assert(!this->verify_chunk_in_free_list(chunk), "Double entry");
+  // This is expensive for metaspace
+  assert(!FLSVerifyDictionary || !this->verify_chunk_in_free_list(chunk), "Double entry");
   assert(head() == NULL || head()->prev() == NULL, "list invariant");
   assert(tail() == NULL || tail()->next() == NULL, "list invariant");
 
@@ -253,7 +254,8 @@
   assert(chunk->list() == this, "list should be set for chunk");
   assert(head() != NULL, "The tree list is embedded in the first chunk");
   assert(chunk != NULL, "returning NULL chunk");
-  assert(!this->verify_chunk_in_free_list(chunk), "Double entry");
+  // This is expensive for metaspace
+  assert(!FLSVerifyDictionary || !this->verify_chunk_in_free_list(chunk), "Double entry");
   assert(head() == NULL || head()->prev() == NULL, "list invariant");
   assert(tail() == NULL || tail()->next() == NULL, "list invariant");