X-Git-Url: http://demsky.eecs.uci.edu/git/?a=blobdiff_plain;f=folly%2Fexperimental%2Fhazptr%2Fhazptr.h;h=21df54e6bab443cd2a20973bbf577781021e6a89;hb=73fbda10ad950396a9869ebc60df8f2ef52cd5f8;hp=5c71b34eefb0289ca81b4b79efadc38a64d4be2c;hpb=e52b296424c9441b5595906674045e04c6ccf24a;p=folly.git diff --git a/folly/experimental/hazptr/hazptr.h b/folly/experimental/hazptr/hazptr.h index 5c71b34e..21df54e6 100644 --- a/folly/experimental/hazptr/hazptr.h +++ b/folly/experimental/hazptr/hazptr.h @@ -80,6 +80,9 @@ class hazptr_domain { std::atomic retired_ = {nullptr}; std::atomic hcount_ = {0}; std::atomic rcount_ = {0}; + /* Using signed int for rcount_ because it may transiently be + * negative. Using signed int for all integer variables that may be + * involved in calculations related to the value of rcount_. */ void objRetire(hazptr_obj*); hazptr_rec* hazptrAcquire();