| 59 | } |
| 60 | |
| 61 | void CSRNodeGroup::initializeScanState(const Transaction* transaction, |
| 62 | TableScanState& state) const { |
| 63 | auto& relScanState = state.cast<RelTableScanState>(); |
| 64 | DASSERT(relScanState.nodeGroupScanState); |
| 65 | auto& nodeGroupScanState = relScanState.nodeGroupScanState->cast<CSRNodeGroupScanState>(); |
| 66 | if (relScanState.nodeGroupIdx != nodeGroupIdx || relScanState.randomLookup) { |
| 67 | relScanState.nodeGroupIdx = nodeGroupIdx; |
| 68 | if (persistentChunkGroup) { |
| 69 | initScanForCommittedPersistent(transaction, relScanState, nodeGroupScanState); |
| 70 | } |
| 71 | } |
| 72 | // Switch to a new Vector of bound nodes (i.e., new csr lists) in the node group. |
| 73 | if (persistentChunkGroup) { |
| 74 | nodeGroupScanState.nextRowToScan = 0; |
| 75 | nodeGroupScanState.numCachedRows = 0; |
| 76 | nodeGroupScanState.nextCachedRowToScan = 0; |
| 77 | nodeGroupScanState.source = CSRNodeGroupScanSource::COMMITTED_PERSISTENT; |
| 78 | } else if (csrIndex) { |
| 79 | initScanForCommittedInMem(relScanState, nodeGroupScanState); |
| 80 | } else { |
| 81 | nodeGroupScanState.source = CSRNodeGroupScanSource::NONE; |
| 82 | nodeGroupScanState.nextRowToScan = 0; |
| 83 | } |
| 84 | } |
| 85 | |
| 86 | void CSRNodeGroup::initScanForCommittedPersistent(const Transaction* transaction, |
| 87 | RelTableScanState& relScanState, CSRNodeGroupScanState& nodeGroupScanState) const { |
no outgoing calls
no test coverage detected