16 #ifndef IMPALA_EXEC_OLD_HASH_TABLE_INLINE_H
17 #define IMPALA_EXEC_OLD_HASH_TABLE_INLINE_H
28 Node* node = bucket->node;
29 while (node != NULL) {
31 return Iterator(
this, bucket_idx, node, hash);
39 int64_t bucket_idx = -1;
41 if (bucket != NULL)
return Iterator(
this, bucket_idx, bucket->
node, 0);
46 int64_t bucket_idx = -1;
48 while (bucket != NULL) {
50 while (node != NULL && node->
matched) {
57 return Iterator(
this, bucket_idx, node, 0);
112 if (previous_node != NULL) {
122 template<
bool check_match>
133 while (node != NULL) {
150 if (bucket == NULL) {
160 if (bucket_idx_ == -1)
return false;
162 while (node_->next != NULL && node_->next->matched) {
165 if (node_->next == NULL) {
167 Bucket* bucket = table_->NextBucket(&bucket_idx_);
168 if (bucket == NULL) {
173 node_ = bucket->
node;
174 if (node_ != NULL && !node_->matched)
return true;
177 DCHECK(!node_->next->matched);
stl-like iterator interface.
std::vector< Bucket > buckets_
uint32_t IR_NO_INLINE HashCurrentRow()
int64_t num_filled_buckets_
Number of non-empty buckets. Used to determine when to grow and rehash.
Node * node_
Current node idx (within current bucket)
const StringSearch UrlParser::hash_search & hash
TupleRow * GetRow(Node *node) const
uint32_t scan_hash_
Cached hash value for the row passed to Find()
bool IR_NO_INLINE EvalProbeRow(TupleRow *row)
Bucket * NextBucket(int64_t *bucket_idx)
Iterator FirstUnmatched()
bool IR_NO_INLINE EvalBuildRow(TupleRow *row)
bool IR_ALWAYS_INLINE EvalAndHashProbe(TupleRow *row, uint32_t *hash)
int node_remaining_current_page_
Number of nodes left in the current page.
Node * next_node_
Next node to insert.
bool IR_ALWAYS_INLINE InsertImpl(void *data)
Insert row into the hash table.
void GrowNodeArray()
Grow the node array.
int64_t num_buckets_
equal to buckets_.size() but more efficient than the size function
Iterator End()
Returns end marker.
void AddToBucket(Bucket *bucket, Node *node)
void IR_ALWAYS_INLINE Next()
Iterator IR_ALWAYS_INLINE Find(TupleRow *probe_row)
bool IR_ALWAYS_INLINE EvalAndHashBuild(TupleRow *row, uint32_t *hash)
bool Equals(TupleRow *build_row)
void MoveNode(Bucket *from_bucket, Bucket *to_bucket, Node *node, Node *previous_node)
int64_t num_nodes_
number of nodes stored (i.e. size of hash table)
int64_t bucket_idx_
Current bucket idx.