MCPcopy Create free account
hub / github.com/activeloopai/deeplake / deeplake_scan_analyze_next_tuple

Function deeplake_scan_analyze_next_tuple

cpp/deeplake_pg/table_am.cpp:287–314  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

285}
286
287bool deeplake_scan_analyze_next_tuple(
288 TableScanDesc scan, TransactionId OldestXmin, double* liverows, double* deadrows, TupleTableSlot* slot)
289{
290 CHECK_FOR_INTERRUPTS();
291
292 DeeplakeScanData* scan_data = get_scan_data(scan);
293 if (scan_data == nullptr) {
294 return false;
295 }
296
297 if (!scan_data->scan_state.get_next_tuple(slot)) {
298 return false; // no more tuples
299 }
300
301 /*
302 * For columnar DeepLake we don't track tuple visibility like heap.
303 * All tuples are live, there are never dead tuples in columnar storage.
304 */
305 if (liverows) {
306 *liverows += 1.0;
307 }
308
309 // IMPORTANT: Always keep deadrows at 0 for columnar storage
310 // We don't have MVCC dead tuples in columnar format
311 // Don't increment deadrows even if pointer is not null
312
313 return true;
314}
315
316#if PG_VERSION_NUM >= PG_VERSION_NUM_17
317bool deeplake_scan_analyze_next_block(TableScanDesc scan, ReadStream* stream)

Callers

nothing calls this directly

Calls 2

get_scan_dataFunction · 0.85
get_next_tupleMethod · 0.80

Tested by

no test coverage detected