phoenix icon indicating copy to clipboard operation
phoenix copied to clipboard

PHOENIX-4594: Perform binary search on guideposts during query compilation

Open binshi-bing opened this issue 6 years ago • 1 comments

…instead of linear search for the first guide post in the first region of the targeted scan ranges. In details:

1. The aglorithm continuously decodes and loads guide posts in batches and perform binary search in each batch, until it finds the start key of the first region in the scan ranges or its insertion position.
   There are two reasons to use moving windows to load guide posts in batches.
   a. Firstly, we don't want to load all guide posts in the memory to increase memory footprint.
   b. Secondly, we don't want to decode and load the guide posts beyond the targed scan ranges to increase the system overhead.
2. Added config parameter STATS_GUIDEPOST_MOVING_WINDOW_SIZE to denote the size of moving window used for loading guid posts.

binshi-bing avatar Sep 13 '18 21:09 binshi-bing

@karanmehta93 Can you also review this?

twdsilva avatar Sep 17 '18 18:09 twdsilva