24#ifndef SQL_RANGE_OPTIMIZER_INDEX_RANGE_SCAN_H_
25#define SQL_RANGE_OPTIMIZER_INDEX_RANGE_SCAN_H_
114 double expected_rows,
uint index_arg,
126 bool Init()
override;
142 unsigned mrr_flags,
bool in_ror_merged_scan,
A wrapper class which provides array bounds checking.
Definition: sql_array.h:47
Definition: index_merge.h:99
Definition: index_range_scan.h:61
friend uint quick_range_seq_next(range_seq_t rseq, KEY_MULTI_RANGE *range)
Definition: index_range_scan.cc:160
KEY_PART_INFO * key_part_info
Definition: index_range_scan.h:94
bool free_file
Definition: index_range_scan.h:80
uint index
Definition: index_range_scan.h:65
uint mrr_buf_size
Definition: index_range_scan.h:90
IndexRangeScanIterator(THD *thd, TABLE *table, ha_rows *examined_rows, double expected_rows, uint index_arg, bool need_rows_in_rowid_order, bool reuse_handler, MEM_ROOT *return_mem_root, uint mrr_flags, uint mrr_buf_size, Bounds_checked_array< QUICK_RANGE * > ranges)
Definition: index_range_scan.cc:56
MEM_ROOT * mem_root
Definition: index_range_scan.h:100
const bool m_expected_rows
Definition: index_range_scan.h:102
uchar * last_rowid() const override
Definition: index_range_scan.h:135
QUICK_RANGE_SEQ_CTX qr_traversal_ctx
Definition: index_range_scan.h:87
uint mrr_flags
Definition: index_range_scan.h:89
HANDLER_BUFFER * mrr_buf_desc
Definition: index_range_scan.h:91
bool Init() override
Initialize or reinitialize the iterator.
Definition: index_range_scan.cc:204
IndexRangeScanIterator(IndexRangeScanIterator &&)=default
bool shared_reset()
Definition: index_range_scan.cc:303
bool shared_init()
Definition: index_range_scan.cc:83
void UnlockRow() override
The default implementation of unlock-row method of RowIterator, used in all access methods except EQR...
Definition: index_range_scan.h:128
IndexRangeScanIterator(const IndexRangeScanIterator &)=delete
QUICK_RANGE * last_range
Definition: index_range_scan.h:84
uint get_mrr_flags() const
Definition: index_range_scan.h:134
Bounds_checked_array< QUICK_RANGE * > ranges
Definition: index_range_scan.h:79
int Read() override
Read a single row.
Definition: index_range_scan.cc:352
bool inited
Definition: index_range_scan.h:101
ha_rows * m_examined_rows
Definition: index_range_scan.h:103
bool row_in_ranges()
Definition: index_range_scan.cc:402
QUICK_RANGE ** cur_range
Definition: index_range_scan.h:83
const bool need_rows_in_rowid_order
Definition: index_range_scan.h:96
handler * file
Definition: index_range_scan.h:63
bool in_ror_merged_scan
Definition: index_range_scan.h:68
friend range_seq_t quick_range_seq_init(void *init_param, uint n_ranges, uint flags)
Definition: index_range_scan.cc:130
~IndexRangeScanIterator() override
Definition: index_range_scan.cc:100
bool init_ror_merged_scan()
Definition: rowid_ordered_retrieval.cc:79
int cmp_next(QUICK_RANGE *range)
Definition: index_range_scan.cc:429
MY_BITMAP column_bitmap
Definition: index_range_scan.h:71
int cmp_prev(QUICK_RANGE *range)
Definition: index_range_scan.cc:442
const bool reuse_handler
Definition: index_range_scan.h:97
super::const_iterator const_iterator
Definition: mem_root_array.h:433
Definition: range_optimizer.h:69
Definition: range_opt_param.h:29
An interface for RowIterators that have a given row ID, ie., they can be children in ROR (rowid-order...
Definition: rowid_capable_row_iterator.h:36
Definition: rowid_ordered_retrieval.h:63
THD * thd() const
Definition: row_iterator.h:228
A graph of (possible multiple) key ranges, represented as a red-black binary tree.
Definition: tree.h:68
Using this class is fraught with peril, and you need to be very careful when doing so.
Definition: sql_string.h:168
For each client connection we create a separate thread with THD serving as a thread/connection descri...
Definition: sql_lexer_thd.h:34
TABLE * table() const
Definition: row_iterator.h:246
The handler class is the interface for dynamically loadable storage engines.
Definition: handler.h:4414
static int flags[50]
Definition: hp_test1.cc:40
uint quick_range_seq_next(range_seq_t rseq, KEY_MULTI_RANGE *range)
Definition: index_range_scan.cc:160
range_seq_t quick_range_seq_init(void *init_param, uint, uint)
Definition: index_range_scan.cc:130
bool InitIndexRangeScan(TABLE *table, handler *file, int index, unsigned mrr_flags, bool in_ror_merged_scan, MY_BITMAP *column_bitmap)
Definition: index_range_scan.cc:251
my_off_t ha_rows
Definition: my_base.h:1140
Some integer typedefs for easier portability.
unsigned char uchar
Definition: my_inttypes.h:52
void * range_seq_t
Definition: handler.h:3651
Definition: handler.h:3645
Definition: my_base.h:1131
The MEM_ROOT is a simple arena, where allocations are carved out of larger blocks.
Definition: my_alloc.h:83
Definition: my_bitmap.h:43
Definition: index_range_scan.h:51
Quick_ranges::const_iterator cur
Definition: index_range_scan.h:53
Quick_ranges::const_iterator last
Definition: index_range_scan.h:54
Quick_ranges::const_iterator first
Definition: index_range_scan.h:52
Definition: gen_lex_token.cc:149
unsigned int uint
Definition: uca9-dump.cc:75