MCPcopy Create free account
hub / github.com/MariaDB/server / index_blocks

Method index_blocks

sql/handler.cc:3722–3730  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3720*/
3721
3722ulonglong handler::index_blocks(uint index, uint ranges, ha_rows rows)
3723{
3724 if (!stats.block_size)
3725 return 0; // No disk storage
3726 size_t len= table->key_storage_length(index);
3727 ulonglong blocks= (rows * len / INDEX_BLOCK_FILL_FACTOR_DIV *
3728 INDEX_BLOCK_FILL_FACTOR_MUL) / stats.block_size + ranges;
3729 return blocks * stats.block_size / IO_SIZE;
3730}
3731
3732
3733/*

Callers 2

check_quick_selectFunction · 0.45
cost_for_index_readFunction · 0.45

Calls 1

key_storage_lengthMethod · 0.80

Tested by

no test coverage detected