src/hotspot/share/memory/metaspace/counter.hpp
branchstuefe-new-metaspace-branch
changeset 59257 990b1fed3b47
parent 58227 0e7d9a23261e
equal deleted inserted replaced
59238:6ce12ce00d3e 59257:990b1fed3b47
    33 
    33 
    34 
    34 
    35 namespace metaspace {
    35 namespace metaspace {
    36 
    36 
    37 // A very simple helper class which counts something, offers decrement/increment
    37 // A very simple helper class which counts something, offers decrement/increment
    38 // methods and checks for overflow/underflow on increment/decrement.
    38 // methods and, on debug, checks for overflow/underflow on increment/decrement.
    39 //
    39 //
    40 // (since we seem to do that alot....)
    40 // Two variants exists, a thread-safe one using atomic counting, a normal one
    41 
    41 //  which does not.
    42 template <class T>
    42 template <class T>
    43 class AbstractCounter {
    43 class AbstractCounter {
    44 
    44 
    45   T _c;
    45   T _c;
    46 
    46