• Robert Haas's avatar
    Postpone generate_gather_paths for topmost scan/join rel. · 3f90ec85
    Robert Haas authored
    Don't call generate_gather_paths for the topmost scan/join relation
    when it is initially populated with paths.  Instead, do the work in
    grouping_planner.  By itself, this gains nothing; in fact it loses
    slightly because we end up calling set_cheapest() for the topmost
    scan/join rel twice rather than once.  However, it paves the way for
    a future commit which will postpone generate_gather_paths for the
    topmost scan/join relation even further, allowing more accurate
    costing of parallel paths.
    
    Amit Kapila and Robert Haas.  Earlier versions of this patch (which
    different substantially) were reviewed by Dilip Kumar, Amit
    Khandekar, Marina Polyakova, and Ashutosh Bapat.
    3f90ec85
allpaths.c 116 KB