Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
8260263: Remove PtrQueue::_qset
Remove dead code related to PtrQueue::_qset and itself.

Reviewed-by: kbarrett, sjohanss
  • Loading branch information
Thomas Schatzl committed Jan 25, 2021
1 parent 5898ab6 commit d825339
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 24 deletions.
6 changes: 0 additions & 6 deletions src/hotspot/share/gc/g1/g1DirtyCardQueue.hpp
Expand Up @@ -49,8 +49,6 @@ class G1DirtyCardQueue: public PtrQueue {
// doing something else, with auto-flush on completion.
~G1DirtyCardQueue();

inline G1DirtyCardQueueSet* dirty_card_qset() const;

G1ConcurrentRefineStats* refinement_stats() const {
return _refinement_stats;
}
Expand Down Expand Up @@ -351,8 +349,4 @@ class G1DirtyCardQueueSet: public PtrQueueSet {
void discard_max_cards_padding();
};

inline G1DirtyCardQueueSet* G1DirtyCardQueue::dirty_card_qset() const {
return static_cast<G1DirtyCardQueueSet*>(qset());
}

#endif // SHARE_GC_G1_G1DIRTYCARDQUEUE_HPP
1 change: 0 additions & 1 deletion src/hotspot/share/gc/shared/ptrQueue.cpp
Expand Up @@ -36,7 +36,6 @@
#include <new>

PtrQueue::PtrQueue(PtrQueueSet* qset) :
_qset(qset),
_index(0),
_capacity_in_bytes(index_to_byte_index(qset->buffer_size())),
_buf(NULL)
Expand Down
5 changes: 0 additions & 5 deletions src/hotspot/share/gc/shared/ptrQueue.hpp
Expand Up @@ -44,9 +44,6 @@ class PtrQueue {

NONCOPYABLE(PtrQueue);

// The ptr queue set to which this queue belongs.
PtrQueueSet* const _qset;

// The (byte) index at which an object was last enqueued. Starts at
// capacity (in bytes) (indicating an empty buffer) and goes towards zero.
// Value is always pointer-size aligned.
Expand Down Expand Up @@ -77,8 +74,6 @@ class PtrQueue {
// The buffer.
void** _buf;

PtrQueueSet* qset() const { return _qset; }

// Initialize this queue to contain a null buffer, and be part of the
// given PtrQueueSet.
PtrQueue(PtrQueueSet* qset);
Expand Down
15 changes: 3 additions & 12 deletions src/hotspot/share/gc/shared/satbMarkQueue.hpp
Expand Up @@ -54,16 +54,15 @@ class SATBMarkQueue: public PtrQueue {
// active state, to support inline barriers in compiled code.
bool _active;

// Filter out unwanted entries from the buffer.
inline void filter();

public:
SATBMarkQueue(SATBMarkQueueSet* qset);

bool is_active() const { return _active; }
void set_active(bool value) { _active = value; }

inline SATBMarkQueueSet* satb_qset() const;
// Apply cl to the active part of the buffer.
// Prerequisite: Must be at a safepoint.
void apply_closure_and_empty(SATBBufferClosure* cl);

#ifndef PRODUCT
// Helpful for debugging
Expand Down Expand Up @@ -174,14 +173,6 @@ class SATBMarkQueueSet: public PtrQueueSet {
void abandon_partial_marking();
};

inline SATBMarkQueueSet* SATBMarkQueue::satb_qset() const {
return static_cast<SATBMarkQueueSet*>(qset());
}

inline void SATBMarkQueue::filter() {
satb_qset()->filter(*this);
}

// Removes entries from queue's buffer that are no longer needed, as
// determined by filter. If e is a void* entry in queue's buffer,
// filter_out(e) must be a valid expression whose value is convertible
Expand Down

1 comment on commit d825339

@openjdk-notifier
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.