| 4116 | #endif |
| 4117 | |
| 4118 | static void |
| 4119 | batch_alloc_prof_sample_assert(tsd_t *tsd, size_t batch, size_t usize) { |
| 4120 | assert(config_prof && opt_prof); |
| 4121 | bool prof_sample_event = te_prof_sample_event_lookahead(tsd, |
| 4122 | batch * usize); |
| 4123 | assert(!prof_sample_event); |
| 4124 | size_t surplus; |
| 4125 | prof_sample_event = te_prof_sample_event_lookahead_surplus(tsd, |
| 4126 | (batch + 1) * usize, &surplus); |
| 4127 | assert(prof_sample_event); |
| 4128 | assert(surplus < usize); |
| 4129 | } |
| 4130 | |
| 4131 | size_t |
| 4132 | batch_alloc(void **ptrs, size_t num, size_t size, int flags) { |
no test coverage detected