Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
LizBing committed Dec 23, 2023
1 parent cf5ccce commit 1729483
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
14 changes: 7 additions & 7 deletions src/hotspot/share/gc/g1/g1CollectedHeap.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -309,13 +309,13 @@ class G1CollectedHeap : public CollectedHeap {
// These are assert functions so that, if the assert fires, we get the correct
// line number, file, etc.
public:
static void assert_heap_locked() NOT_DEBUG_RETURN;
static void assert_heap_locked_or_at_safepoint(bool should_be_vm_thread) NOT_DEBUG_RETURN;
static void assert_heap_locked_and_not_at_safepoint() NOT_DEBUG_RETURN;
static void assert_heap_not_locked() NOT_DEBUG_RETURN;
static void assert_heap_not_locked_and_not_at_safepoint() NOT_DEBUG_RETURN;
static void assert_at_safepoint_on_vm_thread() NOT_DEBUG_RETURN;
static void assert_used_and_recalculate_used_equal(G1CollectedHeap* g1h) NOT_DEBUG_RETURN;
inline static void assert_heap_locked() NOT_DEBUG_RETURN;
inline static void assert_heap_locked_or_at_safepoint(bool should_be_vm_thread) NOT_DEBUG_RETURN;
inline static void assert_heap_locked_and_not_at_safepoint() NOT_DEBUG_RETURN;
inline static void assert_heap_not_locked() NOT_DEBUG_RETURN;
inline static void assert_heap_not_locked_and_not_at_safepoint() NOT_DEBUG_RETURN;
inline static void assert_at_safepoint_on_vm_thread() NOT_DEBUG_RETURN;
inline static void assert_used_and_recalculate_used_equal(G1CollectedHeap* g1h) NOT_DEBUG_RETURN;

private:
// The young region list.
Expand Down
2 changes: 1 addition & 1 deletion src/hotspot/share/gc/g1/g1CollectedHeap.inline.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -361,7 +361,7 @@ inline void G1CollectedHeap::assert_at_safepoint_on_vm_thread() {

inline void G1CollectedHeap::
assert_used_and_recalculate_used_equal(G1CollectedHeap* g1h) {
#if ASSERT
#ifdef ASSERT
size_t cur_used_bytes = g1h->used();
size_t recal_used_bytes = g1h->recalculate_used();
assert(cur_used_bytes == recal_used_bytes, "Used(" SIZE_FORMAT ") is not"
Expand Down

0 comments on commit 1729483

Please sign in to comment.