SmallLeafHeapBucket.cpp 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. //-------------------------------------------------------------------------------------------------------
  2. // Copyright (C) Microsoft. All rights reserved.
  3. // Licensed under the MIT license. See LICENSE.txt file in the project root for full license information.
  4. //-------------------------------------------------------------------------------------------------------
  5. #include "CommonMemoryPch.h"
  6. template <typename TBlockAttributes>
  7. void
  8. SmallLeafHeapBucketT<TBlockAttributes>::Sweep(RecyclerSweep& recyclerSweep)
  9. {
  10. BaseT::SweepBucket(recyclerSweep, [](RecyclerSweep& recyclerSweep){});
  11. }
  12. #if DBG || defined(RECYCLER_SLOW_CHECK_ENABLED)
  13. template <typename TBlockAttributes>
  14. size_t
  15. SmallLeafHeapBucketT<TBlockAttributes>::GetNonEmptyHeapBlockCount(bool checkCount) const
  16. {
  17. return BaseT::GetNonEmptyHeapBlockCount(checkCount);
  18. }
  19. #endif
  20. #ifdef RECYCLER_SLOW_CHECK_ENABLED
  21. template <typename TBlockAttributes>
  22. size_t
  23. SmallLeafHeapBucketT<TBlockAttributes>::Check()
  24. {
  25. return BaseT::Check(true);
  26. }
  27. #endif
  28. #ifdef RECYCLER_MEMORY_VERIFY
  29. template <typename TBlockAttributes>
  30. void
  31. SmallLeafHeapBucketT<TBlockAttributes>::Verify()
  32. {
  33. BaseT::Verify();
  34. }
  35. #endif
  36. #ifdef RECYCLER_VERIFY_MARK
  37. template <typename TBlockAttributes>
  38. void
  39. SmallLeafHeapBucketT<TBlockAttributes>::VerifyMark()
  40. {
  41. __super::VerifyMark();
  42. }
  43. #endif
  44. namespace Memory
  45. {
  46. template class SmallLeafHeapBucketT<SmallAllocationBlockAttributes>;
  47. template class SmallLeafHeapBucketT<MediumAllocationBlockAttributes>;
  48. }