| 138 | }; |
| 139 | |
| 140 | inline bool Sampler::SampleAllocation(size_t k) { |
| 141 | if (bytes_until_sample_ < k) { |
| 142 | bytes_until_sample_ = PickNextSamplingPoint(); |
| 143 | return true; |
| 144 | } else { |
| 145 | bytes_until_sample_ -= k; |
| 146 | return false; |
| 147 | } |
| 148 | } |
| 149 | |
| 150 | // Inline functions which are public for testing purposes |
| 151 |
no outgoing calls
no test coverage detected