* create_partial_bitmap_paths * Build partial bitmap heap path for the relation */
| 4650 | * Build partial bitmap heap path for the relation |
| 4651 | */ |
| 4652 | void |
| 4653 | create_partial_bitmap_paths(PlannerInfo *root, RelOptInfo *rel, |
| 4654 | Path *bitmapqual) |
| 4655 | { |
| 4656 | int parallel_workers; |
| 4657 | double pages_fetched; |
| 4658 | |
| 4659 | /* Compute heap pages for bitmap heap scan */ |
| 4660 | pages_fetched = compute_bitmap_pages(root, rel, bitmapqual, 1.0, |
| 4661 | NULL, NULL); |
| 4662 | |
| 4663 | |
| 4664 | /* |
| 4665 | * Don't support parallel BitmapScan for AO/AOCS. |
| 4666 | */ |
| 4667 | if (rel->reloptkind == RELOPT_BASEREL && (AMHandlerIsAO(rel->amhandler))) |
| 4668 | return; |
| 4669 | |
| 4670 | parallel_workers = compute_parallel_worker(root, rel, pages_fetched, -1, |
| 4671 | max_parallel_workers_per_gather); |
| 4672 | |
| 4673 | if (parallel_workers <= 1) |
| 4674 | return; |
| 4675 | |
| 4676 | add_partial_path(rel, (Path *) create_bitmap_heap_path(root, rel, |
| 4677 | bitmapqual, rel->lateral_relids, 1.0, parallel_workers)); |
| 4678 | } |
| 4679 | |
| 4680 | /* |
| 4681 | * Compute the number of parallel workers that should be used to scan a |
no test coverage detected