Adjust nodeBitmapIndexscan.c to not keep the index open across calls,
but just to open and close it during MultiExecBitmapIndexScan. This avoids acquiring duplicate resources (eg, multiple locks on the same relation) in a tree with many bitmap scans. Also, don't bother to lock the parent heap at all here, since we must be underneath a BitmapHeapScan node that will be holding a suitable lock.
Showing
Please register or sign in to comment