| 1256 | } |
| 1257 | |
| 1258 | bool Sorter::MustSortAndSpill(const int rows_added, const int batch_num_rows) { |
| 1259 | if (rows_added < batch_num_rows) { |
| 1260 | return true; |
| 1261 | } else if (enforce_sort_run_bytes_limit_) { |
| 1262 | int used_reservation = buffer_pool_client_->GetUsedReservation(); |
| 1263 | return GetSortRunBytesLimit() < used_reservation; |
| 1264 | } |
| 1265 | return false; |
| 1266 | } |
| 1267 | |
| 1268 | void Sorter::TryLowerMemUpToSortRunBytesLimit() { |
| 1269 | DCHECK(enforce_sort_run_bytes_limit_); |
nothing calls this directly
no test coverage detected