Lines Matching defs:sampler
5 #include "src/libsampler/sampler.h"
172 namespace sampler {
202 void SamplerManager::AddSampler(Sampler* sampler) {
204 DCHECK(sampler->IsActive());
205 pthread_t thread_id = sampler->platform_data()->vm_tid();
209 samplers.push_back(sampler);
213 auto sampler_it = std::find(samplers.begin(), samplers.end(), sampler);
214 if (sampler_it == samplers.end()) samplers.push_back(sampler);
218 void SamplerManager::RemoveSampler(Sampler* sampler) {
220 DCHECK(sampler->IsActive());
221 pthread_t thread_id = sampler->platform_data()->vm_tid();
225 samplers.erase(std::remove(samplers.begin(), samplers.end(), sampler),
241 for (Sampler* sampler : samplers) {
242 if (!sampler->ShouldRecordSample()) continue;
243 Isolate* isolate = sampler->isolate();
246 sampler->SampleStack(state);
258 // Win32 profiler support. On Cygwin we use the same sampler implementation as
265 // going to use it in the sampler thread. Using GetThreadHandle() will
623 // deadline to protect against hanging the sampler thread in this case.
660 } // namespace sampler