Repository: hive
Updated Branches:
  refs/heads/master ea1173a54 -> 5553c59e3


http://git-wip-us.apache.org/repos/asf/hive/blob/5553c59e/ql/src/test/results/clientpositive/perf/tez/constraints/query83.q.out
----------------------------------------------------------------------
diff --git 
a/ql/src/test/results/clientpositive/perf/tez/constraints/query83.q.out 
b/ql/src/test/results/clientpositive/perf/tez/constraints/query83.q.out
index 4dd50d1..16f85be 100644
--- a/ql/src/test/results/clientpositive/perf/tez/constraints/query83.q.out
+++ b/ql/src/test/results/clientpositive/perf/tez/constraints/query83.q.out
@@ -145,190 +145,190 @@ POSTHOOK: Output: hdfs://### HDFS PATH ###
 Plan optimized by CBO.
 
 Vertex dependency in root stage
-Reducer 10 <- Reducer 16 (SIMPLE_EDGE), Reducer 9 (SIMPLE_EDGE)
+Reducer 10 <- Map 20 (SIMPLE_EDGE), Reducer 9 (SIMPLE_EDGE)
 Reducer 11 <- Reducer 10 (SIMPLE_EDGE)
-Reducer 12 <- Map 22 (SIMPLE_EDGE), Map 8 (SIMPLE_EDGE)
-Reducer 13 <- Reducer 12 (SIMPLE_EDGE), Reducer 16 (SIMPLE_EDGE)
+Reducer 12 <- Map 22 (SIMPLE_EDGE), Reducer 2 (SIMPLE_EDGE)
+Reducer 13 <- Map 20 (SIMPLE_EDGE), Reducer 12 (SIMPLE_EDGE)
 Reducer 14 <- Reducer 13 (SIMPLE_EDGE)
-Reducer 16 <- Map 15 (SIMPLE_EDGE), Reducer 19 (ONE_TO_ONE_EDGE)
-Reducer 18 <- Map 17 (SIMPLE_EDGE), Map 20 (SIMPLE_EDGE)
-Reducer 19 <- Reducer 18 (SIMPLE_EDGE)
-Reducer 2 <- Map 1 (SIMPLE_EDGE), Map 8 (SIMPLE_EDGE)
-Reducer 3 <- Reducer 16 (SIMPLE_EDGE), Reducer 2 (SIMPLE_EDGE)
-Reducer 4 <- Reducer 3 (SIMPLE_EDGE)
-Reducer 5 <- Reducer 11 (ONE_TO_ONE_EDGE), Reducer 4 (ONE_TO_ONE_EDGE)
-Reducer 6 <- Reducer 14 (ONE_TO_ONE_EDGE), Reducer 5 (ONE_TO_ONE_EDGE)
-Reducer 7 <- Reducer 6 (SIMPLE_EDGE)
-Reducer 9 <- Map 21 (SIMPLE_EDGE), Map 8 (SIMPLE_EDGE)
+Reducer 16 <- Map 15 (SIMPLE_EDGE), Map 18 (SIMPLE_EDGE)
+Reducer 17 <- Reducer 16 (SIMPLE_EDGE)
+Reducer 2 <- Map 1 (SIMPLE_EDGE), Reducer 17 (ONE_TO_ONE_EDGE)
+Reducer 3 <- Map 19 (SIMPLE_EDGE), Reducer 2 (SIMPLE_EDGE)
+Reducer 4 <- Map 20 (SIMPLE_EDGE), Reducer 3 (SIMPLE_EDGE)
+Reducer 5 <- Reducer 4 (SIMPLE_EDGE)
+Reducer 6 <- Reducer 11 (ONE_TO_ONE_EDGE), Reducer 5 (ONE_TO_ONE_EDGE)
+Reducer 7 <- Reducer 14 (ONE_TO_ONE_EDGE), Reducer 6 (ONE_TO_ONE_EDGE)
+Reducer 8 <- Reducer 7 (SIMPLE_EDGE)
+Reducer 9 <- Map 21 (SIMPLE_EDGE), Reducer 2 (SIMPLE_EDGE)
 
 Stage-0
   Fetch Operator
     limit:100
     Stage-1
-      Reducer 7 vectorized
-      File Output Operator [FS_395]
-        Limit [LIM_394] (rows=57 width=260)
+      Reducer 8 vectorized
+      File Output Operator [FS_398]
+        Limit [LIM_397] (rows=100 width=260)
           Number of rows:100
-          Select Operator [SEL_393] (rows=57 width=260)
+          Select Operator [SEL_396] (rows=1260 width=260)
             
Output:["_col0","_col1","_col2","_col3","_col4","_col5","_col6","_col7"]
-          <-Reducer 6 [SIMPLE_EDGE]
-            SHUFFLE [RS_124]
-              Select Operator [SEL_123] (rows=57 width=260)
+          <-Reducer 7 [SIMPLE_EDGE]
+            SHUFFLE [RS_121]
+              Select Operator [SEL_120] (rows=1260 width=260)
                 
Output:["_col0","_col1","_col2","_col3","_col4","_col5","_col6","_col7"]
-                Merge Join Operator [MERGEJOIN_360] (rows=57 width=132)
-                  
Conds:RS_120._col0=RS_392._col0(Inner),Output:["_col0","_col1","_col3","_col5","_col6"]
+                Merge Join Operator [MERGEJOIN_363] (rows=1260 width=132)
+                  
Conds:RS_117._col0=RS_395._col0(Inner),Output:["_col0","_col1","_col3","_col5","_col6"]
                 <-Reducer 14 [ONE_TO_ONE_EDGE] vectorized
-                  FORWARD [RS_392]
+                  FORWARD [RS_395]
                     PartitionCols:_col0
-                    Select Operator [SEL_391] (rows=57 width=116)
+                    Select Operator [SEL_394] (rows=1260 width=116)
                       Output:["_col0","_col1","_col2"]
-                      Group By Operator [GBY_390] (rows=57 width=108)
+                      Group By Operator [GBY_393] (rows=1260 width=108)
                         
Output:["_col0","_col1"],aggregations:["sum(VALUE._col0)"],keys:KEY._col0
                       <-Reducer 13 [SIMPLE_EDGE]
-                        SHUFFLE [RS_114]
+                        SHUFFLE [RS_111]
                           PartitionCols:_col0
-                          Group By Operator [GBY_113] (rows=57 width=108)
-                            
Output:["_col0","_col1"],aggregations:["sum(_col2)"],keys:_col4
-                            Merge Join Operator [MERGEJOIN_358] (rows=2521 
width=100)
-                              
Conds:RS_109._col0=RS_110._col0(Inner),Output:["_col2","_col4"]
-                            <-Reducer 16 [SIMPLE_EDGE]
-                              SHUFFLE [RS_110]
+                          Group By Operator [GBY_110] (rows=1260 width=108)
+                            
Output:["_col0","_col1"],aggregations:["sum(_col5)"],keys:_col7
+                            Merge Join Operator [MERGEJOIN_361] (rows=2521 
width=100)
+                              
Conds:RS_106._col4=RS_382._col0(Inner),Output:["_col5","_col7"]
+                            <-Map 20 [SIMPLE_EDGE] vectorized
+                              SHUFFLE [RS_382]
                                 PartitionCols:_col0
-                                Merge Join Operator [MERGEJOIN_349] (rows=2 
width=4)
-                                  
Conds:RS_370._col1=RS_379._col0(Inner),Output:["_col0"]
-                                <-Map 15 [SIMPLE_EDGE] vectorized
-                                  SHUFFLE [RS_370]
-                                    PartitionCols:_col1
-                                    Select Operator [SEL_369] (rows=73049 
width=98)
-                                      Output:["_col0","_col1"]
-                                      Filter Operator [FIL_368] (rows=73049 
width=98)
-                                        predicate:d_date is not null
-                                        TableScan [TS_5] (rows=73049 width=98)
-                                          
default@date_dim,date_dim,Tbl:COMPLETE,Col:COMPLETE,Output:["d_date_sk","d_date"]
-                                <-Reducer 19 [ONE_TO_ONE_EDGE] vectorized
-                                  FORWARD [RS_379]
-                                    PartitionCols:_col0
-                                    Group By Operator [GBY_378] (rows=2 
width=94)
-                                      Output:["_col0"],keys:KEY._col0
-                                    <-Reducer 18 [SIMPLE_EDGE]
-                                      SHUFFLE [RS_21]
-                                        PartitionCols:_col0
-                                        Group By Operator [GBY_20] (rows=2 
width=94)
-                                          Output:["_col0"],keys:_col0
-                                          Merge Join Operator [MERGEJOIN_348] 
(rows=5 width=94)
-                                            
Conds:RS_373._col1=RS_377._col0(Left Semi),Output:["_col0"]
-                                          <-Map 17 [SIMPLE_EDGE] vectorized
-                                            SHUFFLE [RS_373]
-                                              PartitionCols:_col1
-                                              Select Operator [SEL_372] 
(rows=73049 width=98)
-                                                Output:["_col0","_col1"]
-                                                Filter Operator [FIL_371] 
(rows=73049 width=98)
-                                                  predicate:(d_date is not 
null and d_week_seq is not null)
-                                                  TableScan [TS_8] (rows=73049 
width=98)
-                                                    
default@date_dim,date_dim,Tbl:COMPLETE,Col:COMPLETE,Output:["d_date","d_week_seq"]
-                                          <-Map 20 [SIMPLE_EDGE] vectorized
-                                            SHUFFLE [RS_377]
-                                              PartitionCols:_col0
-                                              Group By Operator [GBY_376] 
(rows=1 width=4)
-                                                Output:["_col0"],keys:_col0
-                                                Select Operator [SEL_375] 
(rows=2 width=4)
-                                                  Output:["_col0"]
-                                                  Filter Operator [FIL_374] 
(rows=2 width=98)
-                                                    predicate:((d_date) IN 
('1998-01-02', '1998-10-15', '1998-11-10') and d_week_seq is not null)
-                                                    TableScan [TS_11] 
(rows=73049 width=98)
-                                                      
default@date_dim,date_dim,Tbl:COMPLETE,Col:COMPLETE,Output:["d_date","d_week_seq"]
+                                Select Operator [SEL_379] (rows=462000 
width=104)
+                                  Output:["_col0","_col1"]
+                                  TableScan [TS_22] (rows=462000 width=104)
+                                    
default@item,item,Tbl:COMPLETE,Col:COMPLETE,Output:["i_item_sk","i_item_id"]
                             <-Reducer 12 [SIMPLE_EDGE]
-                              SHUFFLE [RS_109]
-                                PartitionCols:_col0
-                                Merge Join Operator [MERGEJOIN_353] 
(rows=13749816 width=107)
-                                  
Conds:RS_389._col1=RS_367._col0(Inner),Output:["_col0","_col2","_col4"]
-                                <-Map 8 [SIMPLE_EDGE] vectorized
-                                  SHUFFLE [RS_367]
+                              SHUFFLE [RS_106]
+                                PartitionCols:_col4
+                                Merge Join Operator [MERGEJOIN_360] (rows=2521 
width=4)
+                                  
Conds:RS_103._col0=RS_392._col0(Inner),Output:["_col4","_col5"]
+                                <-Reducer 2 [SIMPLE_EDGE]
+                                  SHUFFLE [RS_103]
                                     PartitionCols:_col0
-                                    Select Operator [SEL_364] (rows=462000 
width=104)
-                                      Output:["_col0","_col1"]
-                                      TableScan [TS_3] (rows=462000 width=104)
-                                        
default@item,item,Tbl:COMPLETE,Col:COMPLETE,Output:["i_item_sk","i_item_id"]
+                                    Merge Join Operator [MERGEJOIN_351] 
(rows=2 width=4)
+                                      
Conds:RS_366._col1=RS_375._col0(Inner),Output:["_col0"]
+                                    <-Map 1 [SIMPLE_EDGE] vectorized
+                                      SHUFFLE [RS_366]
+                                        PartitionCols:_col1
+                                        Select Operator [SEL_365] (rows=73049 
width=98)
+                                          Output:["_col0","_col1"]
+                                          Filter Operator [FIL_364] 
(rows=73049 width=98)
+                                            predicate:d_date is not null
+                                            TableScan [TS_0] (rows=73049 
width=98)
+                                              
default@date_dim,date_dim,Tbl:COMPLETE,Col:COMPLETE,Output:["d_date_sk","d_date"]
+                                    <-Reducer 17 [ONE_TO_ONE_EDGE] vectorized
+                                      FORWARD [RS_375]
+                                        PartitionCols:_col0
+                                        Group By Operator [GBY_374] (rows=2 
width=94)
+                                          Output:["_col0"],keys:KEY._col0
+                                        <-Reducer 16 [SIMPLE_EDGE]
+                                          SHUFFLE [RS_16]
+                                            PartitionCols:_col0
+                                            Group By Operator [GBY_15] (rows=2 
width=94)
+                                              Output:["_col0"],keys:_col0
+                                              Merge Join Operator 
[MERGEJOIN_350] (rows=5 width=94)
+                                                
Conds:RS_369._col1=RS_373._col0(Left Semi),Output:["_col0"]
+                                              <-Map 15 [SIMPLE_EDGE] vectorized
+                                                SHUFFLE [RS_369]
+                                                  PartitionCols:_col1
+                                                  Select Operator [SEL_368] 
(rows=73049 width=98)
+                                                    Output:["_col0","_col1"]
+                                                    Filter Operator [FIL_367] 
(rows=73049 width=98)
+                                                      predicate:(d_date is not 
null and d_week_seq is not null)
+                                                      TableScan [TS_3] 
(rows=73049 width=98)
+                                                        
default@date_dim,date_dim,Tbl:COMPLETE,Col:COMPLETE,Output:["d_date","d_week_seq"]
+                                              <-Map 18 [SIMPLE_EDGE] vectorized
+                                                SHUFFLE [RS_373]
+                                                  PartitionCols:_col0
+                                                  Group By Operator [GBY_372] 
(rows=1 width=4)
+                                                    Output:["_col0"],keys:_col0
+                                                    Select Operator [SEL_371] 
(rows=2 width=4)
+                                                      Output:["_col0"]
+                                                      Filter Operator 
[FIL_370] (rows=2 width=98)
+                                                        predicate:((d_date) IN 
('1998-01-02', '1998-10-15', '1998-11-10') and d_week_seq is not null)
+                                                        TableScan [TS_6] 
(rows=73049 width=98)
+                                                          
default@date_dim,date_dim,Tbl:COMPLETE,Col:COMPLETE,Output:["d_date","d_week_seq"]
                                 <-Map 22 [SIMPLE_EDGE] vectorized
-                                  SHUFFLE [RS_389]
-                                    PartitionCols:_col1
-                                    Select Operator [SEL_388] (rows=13749816 
width=11)
+                                  SHUFFLE [RS_392]
+                                    PartitionCols:_col0
+                                    Select Operator [SEL_391] (rows=13749816 
width=11)
                                       Output:["_col0","_col1","_col2"]
-                                      Filter Operator [FIL_387] (rows=13749816 
width=11)
+                                      Filter Operator [FIL_390] (rows=13749816 
width=11)
                                         predicate:wr_returned_date_sk is not 
null
-                                        TableScan [TS_78] (rows=14398467 
width=11)
+                                        TableScan [TS_95] (rows=14398467 
width=11)
                                           
default@web_returns,web_returns,Tbl:COMPLETE,Col:COMPLETE,Output:["wr_returned_date_sk","wr_item_sk","wr_return_quantity"]
-                <-Reducer 5 [ONE_TO_ONE_EDGE]
-                  FORWARD [RS_120]
+                <-Reducer 6 [ONE_TO_ONE_EDGE]
+                  FORWARD [RS_117]
                     PartitionCols:_col0
-                    Merge Join Operator [MERGEJOIN_359] (rows=60 width=116)
-                      
Conds:RS_381._col0=RS_386._col0(Inner),Output:["_col0","_col1","_col3"]
+                    Merge Join Operator [MERGEJOIN_362] (rows=2739 width=116)
+                      
Conds:RS_384._col0=RS_389._col0(Inner),Output:["_col0","_col1","_col3"]
                     <-Reducer 11 [ONE_TO_ONE_EDGE] vectorized
-                      FORWARD [RS_386]
+                      FORWARD [RS_389]
                         PartitionCols:_col0
-                        Group By Operator [GBY_385] (rows=63 width=108)
+                        Group By Operator [GBY_388] (rows=5552 width=108)
                           
Output:["_col0","_col1"],aggregations:["sum(VALUE._col0)"],keys:KEY._col0
                         <-Reducer 10 [SIMPLE_EDGE]
-                          SHUFFLE [RS_75]
+                          SHUFFLE [RS_73]
                             PartitionCols:_col0
-                            Group By Operator [GBY_74] (rows=63 width=108)
-                              
Output:["_col0","_col1"],aggregations:["sum(_col2)"],keys:_col4
+                            Group By Operator [GBY_72] (rows=5552 width=108)
+                              
Output:["_col0","_col1"],aggregations:["sum(_col5)"],keys:_col7
                               Merge Join Operator [MERGEJOIN_357] (rows=11105 
width=100)
-                                
Conds:RS_70._col0=RS_71._col0(Inner),Output:["_col2","_col4"]
-                              <-Reducer 16 [SIMPLE_EDGE]
-                                SHUFFLE [RS_71]
+                                
Conds:RS_68._col4=RS_381._col0(Inner),Output:["_col5","_col7"]
+                              <-Map 20 [SIMPLE_EDGE] vectorized
+                                SHUFFLE [RS_381]
                                   PartitionCols:_col0
-                                   Please refer to the previous Merge Join 
Operator [MERGEJOIN_349]
+                                   Please refer to the previous Select 
Operator [SEL_379]
                               <-Reducer 9 [SIMPLE_EDGE]
-                                SHUFFLE [RS_70]
-                                  PartitionCols:_col0
-                                  Merge Join Operator [MERGEJOIN_350] 
(rows=55578005 width=107)
-                                    
Conds:RS_384._col1=RS_366._col0(Inner),Output:["_col0","_col2","_col4"]
-                                  <-Map 8 [SIMPLE_EDGE] vectorized
-                                    SHUFFLE [RS_366]
+                                SHUFFLE [RS_68]
+                                  PartitionCols:_col4
+                                  Merge Join Operator [MERGEJOIN_356] 
(rows=11105 width=4)
+                                    
Conds:RS_65._col0=RS_387._col0(Inner),Output:["_col4","_col5"]
+                                  <-Reducer 2 [SIMPLE_EDGE]
+                                    SHUFFLE [RS_65]
                                       PartitionCols:_col0
-                                       Please refer to the previous Select 
Operator [SEL_364]
+                                       Please refer to the previous Merge Join 
Operator [MERGEJOIN_351]
                                   <-Map 21 [SIMPLE_EDGE] vectorized
-                                    SHUFFLE [RS_384]
-                                      PartitionCols:_col1
-                                      Select Operator [SEL_383] (rows=55578005 
width=11)
+                                    SHUFFLE [RS_387]
+                                      PartitionCols:_col0
+                                      Select Operator [SEL_386] (rows=55578005 
width=11)
                                         Output:["_col0","_col1","_col2"]
-                                        Filter Operator [FIL_382] 
(rows=55578005 width=11)
+                                        Filter Operator [FIL_385] 
(rows=55578005 width=11)
                                           predicate:sr_returned_date_sk is not 
null
-                                          TableScan [TS_39] (rows=57591150 
width=11)
+                                          TableScan [TS_57] (rows=57591150 
width=11)
                                             
default@store_returns,store_returns,Tbl:COMPLETE,Col:COMPLETE,Output:["sr_returned_date_sk","sr_item_sk","sr_return_quantity"]
-                    <-Reducer 4 [ONE_TO_ONE_EDGE] vectorized
-                      FORWARD [RS_381]
+                    <-Reducer 5 [ONE_TO_ONE_EDGE] vectorized
+                      FORWARD [RS_384]
                         PartitionCols:_col0
-                        Group By Operator [GBY_380] (rows=60 width=108)
+                        Group By Operator [GBY_383] (rows=2739 width=108)
                           
Output:["_col0","_col1"],aggregations:["sum(VALUE._col0)"],keys:KEY._col0
-                        <-Reducer 3 [SIMPLE_EDGE]
-                          SHUFFLE [RS_36]
+                        <-Reducer 4 [SIMPLE_EDGE]
+                          SHUFFLE [RS_35]
                             PartitionCols:_col0
-                            Group By Operator [GBY_35] (rows=60 width=108)
-                              
Output:["_col0","_col1"],aggregations:["sum(_col2)"],keys:_col4
-                              Merge Join Operator [MERGEJOIN_356] (rows=5478 
width=100)
-                                
Conds:RS_31._col0=RS_32._col0(Inner),Output:["_col2","_col4"]
-                              <-Reducer 16 [SIMPLE_EDGE]
-                                SHUFFLE [RS_32]
+                            Group By Operator [GBY_34] (rows=2739 width=108)
+                              
Output:["_col0","_col1"],aggregations:["sum(_col5)"],keys:_col7
+                              Merge Join Operator [MERGEJOIN_353] (rows=5478 
width=100)
+                                
Conds:RS_30._col4=RS_380._col0(Inner),Output:["_col5","_col7"]
+                              <-Map 20 [SIMPLE_EDGE] vectorized
+                                SHUFFLE [RS_380]
                                   PartitionCols:_col0
-                                   Please refer to the previous Merge Join 
Operator [MERGEJOIN_349]
-                              <-Reducer 2 [SIMPLE_EDGE]
-                                SHUFFLE [RS_31]
-                                  PartitionCols:_col0
-                                  Merge Join Operator [MERGEJOIN_347] 
(rows=28798881 width=107)
-                                    
Conds:RS_363._col1=RS_365._col0(Inner),Output:["_col0","_col2","_col4"]
-                                  <-Map 8 [SIMPLE_EDGE] vectorized
-                                    SHUFFLE [RS_365]
+                                   Please refer to the previous Select 
Operator [SEL_379]
+                              <-Reducer 3 [SIMPLE_EDGE]
+                                SHUFFLE [RS_30]
+                                  PartitionCols:_col4
+                                  Merge Join Operator [MERGEJOIN_352] 
(rows=5478 width=4)
+                                    
Conds:RS_27._col0=RS_378._col0(Inner),Output:["_col4","_col5"]
+                                  <-Reducer 2 [SIMPLE_EDGE]
+                                    SHUFFLE [RS_27]
+                                      PartitionCols:_col0
+                                       Please refer to the previous Merge Join 
Operator [MERGEJOIN_351]
+                                  <-Map 19 [SIMPLE_EDGE] vectorized
+                                    SHUFFLE [RS_378]
                                       PartitionCols:_col0
-                                       Please refer to the previous Select 
Operator [SEL_364]
-                                  <-Map 1 [SIMPLE_EDGE] vectorized
-                                    SHUFFLE [RS_363]
-                                      PartitionCols:_col1
-                                      Select Operator [SEL_362] (rows=28798881 
width=11)
+                                      Select Operator [SEL_377] (rows=28798881 
width=11)
                                         Output:["_col0","_col1","_col2"]
-                                        Filter Operator [FIL_361] 
(rows=28798881 width=11)
+                                        Filter Operator [FIL_376] 
(rows=28798881 width=11)
                                           predicate:cr_returned_date_sk is not 
null
-                                          TableScan [TS_0] (rows=28798881 
width=11)
+                                          TableScan [TS_19] (rows=28798881 
width=11)
                                             
default@catalog_returns,catalog_returns,Tbl:COMPLETE,Col:COMPLETE,Output:["cr_returned_date_sk","cr_item_sk","cr_return_quantity"]
 

http://git-wip-us.apache.org/repos/asf/hive/blob/5553c59e/ql/src/test/results/clientpositive/perf/tez/constraints/query85.q.out
----------------------------------------------------------------------
diff --git 
a/ql/src/test/results/clientpositive/perf/tez/constraints/query85.q.out 
b/ql/src/test/results/clientpositive/perf/tez/constraints/query85.q.out
index ec5e4cf..2aa27db 100644
--- a/ql/src/test/results/clientpositive/perf/tez/constraints/query85.q.out
+++ b/ql/src/test/results/clientpositive/perf/tez/constraints/query85.q.out
@@ -186,7 +186,7 @@ Vertex dependency in root stage
 Map 10 <- Reducer 12 (BROADCAST_EDGE)
 Reducer 12 <- Map 11 (CUSTOM_SIMPLE_EDGE)
 Reducer 2 <- Map 1 (SIMPLE_EDGE), Map 10 (SIMPLE_EDGE)
-Reducer 3 <- Map 15 (SIMPLE_EDGE), Reducer 2 (SIMPLE_EDGE)
+Reducer 3 <- Map 14 (SIMPLE_EDGE), Reducer 2 (SIMPLE_EDGE)
 Reducer 4 <- Map 11 (SIMPLE_EDGE), Reducer 3 (SIMPLE_EDGE)
 Reducer 5 <- Map 13 (SIMPLE_EDGE), Reducer 4 (SIMPLE_EDGE)
 Reducer 6 <- Map 14 (SIMPLE_EDGE), Reducer 5 (SIMPLE_EDGE)
@@ -200,121 +200,119 @@ Stage-0
     Stage-1
       Reducer 9 vectorized
       File Output Operator [FS_209]
-        Limit [LIM_208] (rows=7 width=832)
+        Limit [LIM_208] (rows=72 width=832)
           Number of rows:100
-          Select Operator [SEL_207] (rows=7 width=832)
+          Select Operator [SEL_207] (rows=72 width=832)
             Output:["_col0","_col1","_col2","_col3"]
           <-Reducer 8 [SIMPLE_EDGE] vectorized
             SHUFFLE [RS_206]
-              Select Operator [SEL_205] (rows=7 width=832)
+              Select Operator [SEL_205] (rows=72 width=832)
                 Output:["_col4","_col5","_col6","_col7"]
-                Group By Operator [GBY_204] (rows=7 width=353)
+                Group By Operator [GBY_204] (rows=72 width=353)
                   
Output:["_col0","_col1","_col2","_col3","_col4","_col5","_col6"],aggregations:["sum(VALUE._col0)","count(VALUE._col1)","sum(VALUE._col2)","count(VALUE._col3)","sum(VALUE._col4)","count(VALUE._col5)"],keys:KEY._col0
                 <-Reducer 7 [SIMPLE_EDGE]
                   SHUFFLE [RS_42]
                     PartitionCols:_col0
-                    Group By Operator [GBY_41] (rows=7 width=353)
-                      
Output:["_col0","_col1","_col2","_col3","_col4","_col5","_col6"],aggregations:["sum(_col11)","count(_col11)","sum(_col7)","count(_col7)","sum(_col6)","count(_col6)"],keys:_col23
-                      Select Operator [SEL_40] (rows=16740 width=136)
-                        Output:["_col6","_col7","_col11","_col23"]
-                        Filter Operator [FIL_39] (rows=16740 width=136)
-                          predicate:((_col31 and _col32 and _col15) or (_col33 
and _col34 and _col16) or (_col35 and _col36 and _col17))
-                          Merge Join Operator [MERGEJOIN_179] (rows=44640 
width=136)
-                            Conds:RS_36._col1, _col19, _col20=RS_197._col0, 
_col1, 
_col2(Inner),Output:["_col6","_col7","_col11","_col15","_col16","_col17","_col23","_col31","_col32","_col33","_col34","_col35","_col36"]
-                          <-Map 15 [SIMPLE_EDGE] vectorized
-                            SHUFFLE [RS_197]
-                              PartitionCols:_col0, _col1, _col2
-                              Select Operator [SEL_195] (rows=265971 width=207)
-                                
Output:["_col0","_col1","_col2","_col3","_col4","_col5","_col6","_col7","_col8"]
-                                Filter Operator [FIL_194] (rows=265971 
width=183)
-                                  predicate:((cd_education_status) IN ('4 yr 
Degree', 'Primary', 'Advanced Degree') and (cd_marital_status) IN ('M', 'D', 
'U'))
-                                  TableScan [TS_17] (rows=1861800 width=183)
-                                    
default@customer_demographics,cd1,Tbl:COMPLETE,Col:COMPLETE,Output:["cd_demo_sk","cd_marital_status","cd_education_status"]
-                          <-Reducer 6 [SIMPLE_EDGE]
-                            SHUFFLE [RS_36]
-                              PartitionCols:_col1, _col19, _col20
-                              Filter Operator [FIL_35] (rows=44640 width=315)
-                                predicate:((_col25 and _col12) or (_col26 and 
_col13) or (_col27 and _col14))
-                                Merge Join Operator [MERGEJOIN_178] 
(rows=59520 width=315)
-                                  
Conds:RS_32._col2=RS_203._col0(Inner),Output:["_col1","_col6","_col7","_col11","_col12","_col13","_col14","_col15","_col16","_col17","_col19","_col20","_col23","_col25","_col26","_col27"]
-                                <-Map 14 [SIMPLE_EDGE] vectorized
-                                  SHUFFLE [RS_203]
-                                    PartitionCols:_col0
-                                    Select Operator [SEL_202] (rows=3529412 
width=16)
-                                      Output:["_col0","_col1","_col2","_col3"]
-                                      Filter Operator [FIL_201] (rows=3529412 
width=187)
-                                        predicate:((ca_country = 'United 
States') and (ca_state) IN ('KY', 'GA', 'NM', 'MT', 'OR', 'IN', 'WI', 'MO', 
'WV'))
-                                        TableScan [TS_14] (rows=40000000 
width=187)
-                                          
default@customer_address,customer_address,Tbl:COMPLETE,Col:COMPLETE,Output:["ca_address_sk","ca_state","ca_country"]
-                                <-Reducer 5 [SIMPLE_EDGE]
-                                  SHUFFLE [RS_32]
-                                    PartitionCols:_col2
-                                    Merge Join Operator [MERGEJOIN_177] 
(rows=674551 width=350)
-                                      
Conds:RS_29._col4=RS_200._col0(Inner),Output:["_col1","_col2","_col6","_col7","_col11","_col12","_col13","_col14","_col15","_col16","_col17","_col19","_col20","_col23"]
-                                    <-Map 13 [SIMPLE_EDGE] vectorized
-                                      SHUFFLE [RS_200]
-                                        PartitionCols:_col0
-                                        Select Operator [SEL_199] (rows=72 
width=101)
-                                          Output:["_col0","_col1"]
-                                          TableScan [TS_12] (rows=72 width=101)
-                                            
default@reason,reason,Tbl:COMPLETE,Col:COMPLETE,Output:["r_reason_sk","r_reason_desc"]
-                                    <-Reducer 4 [SIMPLE_EDGE]
-                                      SHUFFLE [RS_29]
-                                        PartitionCols:_col4
-                                        Merge Join Operator [MERGEJOIN_176] 
(rows=674551 width=254)
-                                          
Conds:RS_26._col8=RS_185._col0(Inner),Output:["_col1","_col2","_col4","_col6","_col7","_col11","_col12","_col13","_col14","_col15","_col16","_col17","_col19","_col20"]
-                                        <-Map 11 [SIMPLE_EDGE] vectorized
-                                          SHUFFLE [RS_185]
-                                            PartitionCols:_col0
-                                            Select Operator [SEL_184] 
(rows=652 width=4)
-                                              Output:["_col0"]
-                                              Filter Operator [FIL_183] 
(rows=652 width=8)
-                                                predicate:(d_year = 1998)
-                                                TableScan [TS_9] (rows=73049 
width=8)
-                                                  
default@date_dim,date_dim,Tbl:COMPLETE,Col:COMPLETE,Output:["d_date_sk","d_year"]
-                                        <-Reducer 3 [SIMPLE_EDGE]
-                                          SHUFFLE [RS_26]
-                                            PartitionCols:_col8
-                                            Merge Join Operator 
[MERGEJOIN_175] (rows=1889180 width=379)
-                                              
Conds:RS_23._col3=RS_198._col0(Inner),Output:["_col1","_col2","_col4","_col6","_col7","_col8","_col11","_col12","_col13","_col14","_col15","_col16","_col17","_col19","_col20"]
-                                            <-Map 15 [SIMPLE_EDGE] vectorized
-                                              SHUFFLE [RS_198]
-                                                PartitionCols:_col0
-                                                Select Operator [SEL_196] 
(rows=265971 width=183)
-                                                  
Output:["_col0","_col1","_col2"]
-                                                   Please refer to the 
previous Filter Operator [FIL_194]
-                                            <-Reducer 2 [SIMPLE_EDGE]
-                                              SHUFFLE [RS_23]
-                                                PartitionCols:_col3
-                                                Merge Join Operator 
[MERGEJOIN_174] (rows=13039884 width=262)
-                                                  Conds:RS_182._col0, 
_col5=RS_193._col1, 
_col2(Inner),Output:["_col1","_col2","_col3","_col4","_col6","_col7","_col8","_col11","_col12","_col13","_col14","_col15","_col16","_col17"]
-                                                <-Map 1 [SIMPLE_EDGE] 
vectorized
-                                                  SHUFFLE [RS_182]
-                                                    PartitionCols:_col0, _col5
-                                                    Select Operator [SEL_181] 
(rows=11975292 width=237)
-                                                      
Output:["_col0","_col1","_col2","_col3","_col4","_col5","_col6","_col7"]
-                                                      Filter Operator 
[FIL_180] (rows=11975292 width=237)
-                                                        
predicate:(wr_reason_sk is not null and wr_refunded_addr_sk is not null and 
wr_refunded_cdemo_sk is not null and wr_returning_cdemo_sk is not null)
-                                                        TableScan [TS_0] 
(rows=14398467 width=237)
-                                                          
default@web_returns,web_returns,Tbl:COMPLETE,Col:COMPLETE,Output:["wr_item_sk","wr_refunded_cdemo_sk","wr_refunded_addr_sk","wr_returning_cdemo_sk","wr_reason_sk","wr_order_number","wr_fee","wr_refunded_cash"]
-                                                <-Map 10 [SIMPLE_EDGE] 
vectorized
-                                                  SHUFFLE [RS_193]
-                                                    PartitionCols:_col1, _col2
-                                                    Select Operator [SEL_192] 
(rows=15992347 width=39)
-                                                      
Output:["_col0","_col1","_col2","_col3","_col4","_col5","_col6","_col7","_col8","_col9"]
-                                                      Filter Operator 
[FIL_191] (rows=15992347 width=243)
-                                                        
predicate:((ws_net_profit BETWEEN 100 AND 200 or ws_net_profit BETWEEN 150 AND 
300 or ws_net_profit BETWEEN 50 AND 250) and (ws_sales_price BETWEEN 100 AND 
150 or ws_sales_price BETWEEN 50 AND 100 or ws_sales_price BETWEEN 150 AND 200) 
and (ws_sold_date_sk BETWEEN DynamicValue(RS_27_date_dim_d_date_sk_min) AND 
DynamicValue(RS_27_date_dim_d_date_sk_max) and in_bloom_filter(ws_sold_date_sk, 
DynamicValue(RS_27_date_dim_d_date_sk_bloom_filter))) and ws_sold_date_sk is 
not null and ws_web_page_sk is not null)
-                                                        TableScan [TS_3] 
(rows=144002668 width=243)
-                                                          
default@web_sales,web_sales,Tbl:COMPLETE,Col:COMPLETE,Output:["ws_sold_date_sk","ws_item_sk","ws_web_page_sk","ws_order_number","ws_quantity","ws_sales_price","ws_net_profit"]
-                                                        <-Reducer 12 
[BROADCAST_EDGE] vectorized
-                                                          BROADCAST [RS_190]
-                                                            Group By Operator 
[GBY_189] (rows=1 width=12)
-                                                              
Output:["_col0","_col1","_col2"],aggregations:["min(VALUE._col0)","max(VALUE._col1)","bloom_filter(VALUE._col2,
 expectedEntries=1000000)"]
-                                                            <-Map 11 
[CUSTOM_SIMPLE_EDGE] vectorized
-                                                              SHUFFLE [RS_188]
-                                                                Group By 
Operator [GBY_187] (rows=1 width=12)
-                                                                  
Output:["_col0","_col1","_col2"],aggregations:["min(_col0)","max(_col0)","bloom_filter(_col0,
 expectedEntries=1000000)"]
-                                                                  Select 
Operator [SEL_186] (rows=652 width=4)
-                                                                    
Output:["_col0"]
-                                                                     Please 
refer to the previous Select Operator [SEL_184]
+                    Group By Operator [GBY_41] (rows=72 width=353)
+                      
Output:["_col0","_col1","_col2","_col3","_col4","_col5","_col6"],aggregations:["sum(_col11)","count(_col11)","sum(_col7)","count(_col7)","sum(_col6)","count(_col6)"],keys:_col36
+                      Merge Join Operator [MERGEJOIN_179] (rows=16740 
width=100)
+                        
Conds:RS_37._col4=RS_203._col0(Inner),Output:["_col6","_col7","_col11","_col36"]
+                      <-Map 15 [SIMPLE_EDGE] vectorized
+                        SHUFFLE [RS_203]
+                          PartitionCols:_col0
+                          Select Operator [SEL_202] (rows=72 width=101)
+                            Output:["_col0","_col1"]
+                            TableScan [TS_18] (rows=72 width=101)
+                              
default@reason,reason,Tbl:COMPLETE,Col:COMPLETE,Output:["r_reason_sk","r_reason_desc"]
+                      <-Reducer 6 [SIMPLE_EDGE]
+                        SHUFFLE [RS_37]
+                          PartitionCols:_col4
+                          Filter Operator [FIL_36] (rows=16740 width=39)
+                            predicate:((_col29 and _col30 and _col15) or 
(_col31 and _col32 and _col16) or (_col33 and _col34 and _col17))
+                            Merge Join Operator [MERGEJOIN_178] (rows=44640 
width=39)
+                              Conds:RS_33._col20, _col1, _col19=RS_197._col2, 
_col0, 
_col1(Inner),Output:["_col4","_col6","_col7","_col11","_col15","_col16","_col17","_col29","_col30","_col31","_col32","_col33","_col34"]
+                            <-Map 14 [SIMPLE_EDGE] vectorized
+                              SHUFFLE [RS_197]
+                                PartitionCols:_col2, _col0, _col1
+                                Select Operator [SEL_195] (rows=265971 
width=207)
+                                  
Output:["_col0","_col1","_col2","_col3","_col4","_col5","_col6","_col7","_col8"]
+                                  Filter Operator [FIL_194] (rows=265971 
width=183)
+                                    predicate:((cd_education_status) IN ('4 yr 
Degree', 'Primary', 'Advanced Degree') and (cd_marital_status) IN ('M', 'D', 
'U'))
+                                    TableScan [TS_15] (rows=1861800 width=183)
+                                      
default@customer_demographics,cd1,Tbl:COMPLETE,Col:COMPLETE,Output:["cd_demo_sk","cd_marital_status","cd_education_status"]
+                            <-Reducer 5 [SIMPLE_EDGE]
+                              SHUFFLE [RS_33]
+                                PartitionCols:_col20, _col1, _col19
+                                Filter Operator [FIL_32] (rows=44640 width=218)
+                                  predicate:((_col23 and _col12) or (_col24 
and _col13) or (_col25 and _col14))
+                                  Merge Join Operator [MERGEJOIN_177] 
(rows=59520 width=218)
+                                    
Conds:RS_29._col2=RS_201._col0(Inner),Output:["_col1","_col4","_col6","_col7","_col11","_col12","_col13","_col14","_col15","_col16","_col17","_col19","_col20","_col23","_col24","_col25"]
+                                  <-Map 13 [SIMPLE_EDGE] vectorized
+                                    SHUFFLE [RS_201]
+                                      PartitionCols:_col0
+                                      Select Operator [SEL_200] (rows=3529412 
width=16)
+                                        
Output:["_col0","_col1","_col2","_col3"]
+                                        Filter Operator [FIL_199] 
(rows=3529412 width=187)
+                                          predicate:((ca_country = 'United 
States') and (ca_state) IN ('KY', 'GA', 'NM', 'MT', 'OR', 'IN', 'WI', 'MO', 
'WV'))
+                                          TableScan [TS_12] (rows=40000000 
width=187)
+                                            
default@customer_address,customer_address,Tbl:COMPLETE,Col:COMPLETE,Output:["ca_address_sk","ca_state","ca_country"]
+                                  <-Reducer 4 [SIMPLE_EDGE]
+                                    SHUFFLE [RS_29]
+                                      PartitionCols:_col2
+                                      Merge Join Operator [MERGEJOIN_176] 
(rows=674551 width=254)
+                                        
Conds:RS_26._col8=RS_185._col0(Inner),Output:["_col1","_col2","_col4","_col6","_col7","_col11","_col12","_col13","_col14","_col15","_col16","_col17","_col19","_col20"]
+                                      <-Map 11 [SIMPLE_EDGE] vectorized
+                                        SHUFFLE [RS_185]
+                                          PartitionCols:_col0
+                                          Select Operator [SEL_184] (rows=652 
width=4)
+                                            Output:["_col0"]
+                                            Filter Operator [FIL_183] 
(rows=652 width=8)
+                                              predicate:(d_year = 1998)
+                                              TableScan [TS_9] (rows=73049 
width=8)
+                                                
default@date_dim,date_dim,Tbl:COMPLETE,Col:COMPLETE,Output:["d_date_sk","d_year"]
+                                      <-Reducer 3 [SIMPLE_EDGE]
+                                        SHUFFLE [RS_26]
+                                          PartitionCols:_col8
+                                          Merge Join Operator [MERGEJOIN_175] 
(rows=1889180 width=379)
+                                            
Conds:RS_23._col3=RS_198._col0(Inner),Output:["_col1","_col2","_col4","_col6","_col7","_col8","_col11","_col12","_col13","_col14","_col15","_col16","_col17","_col19","_col20"]
+                                          <-Map 14 [SIMPLE_EDGE] vectorized
+                                            SHUFFLE [RS_198]
+                                              PartitionCols:_col0
+                                              Select Operator [SEL_196] 
(rows=265971 width=183)
+                                                
Output:["_col0","_col1","_col2"]
+                                                 Please refer to the previous 
Filter Operator [FIL_194]
+                                          <-Reducer 2 [SIMPLE_EDGE]
+                                            SHUFFLE [RS_23]
+                                              PartitionCols:_col3
+                                              Merge Join Operator 
[MERGEJOIN_174] (rows=13039884 width=262)
+                                                Conds:RS_182._col0, 
_col5=RS_193._col1, 
_col2(Inner),Output:["_col1","_col2","_col3","_col4","_col6","_col7","_col8","_col11","_col12","_col13","_col14","_col15","_col16","_col17"]
+                                              <-Map 1 [SIMPLE_EDGE] vectorized
+                                                SHUFFLE [RS_182]
+                                                  PartitionCols:_col0, _col5
+                                                  Select Operator [SEL_181] 
(rows=11975292 width=237)
+                                                    
Output:["_col0","_col1","_col2","_col3","_col4","_col5","_col6","_col7"]
+                                                    Filter Operator [FIL_180] 
(rows=11975292 width=237)
+                                                      predicate:(wr_reason_sk 
is not null and wr_refunded_addr_sk is not null and wr_refunded_cdemo_sk is not 
null and wr_returning_cdemo_sk is not null)
+                                                      TableScan [TS_0] 
(rows=14398467 width=237)
+                                                        
default@web_returns,web_returns,Tbl:COMPLETE,Col:COMPLETE,Output:["wr_item_sk","wr_refunded_cdemo_sk","wr_refunded_addr_sk","wr_returning_cdemo_sk","wr_reason_sk","wr_order_number","wr_fee","wr_refunded_cash"]
+                                              <-Map 10 [SIMPLE_EDGE] vectorized
+                                                SHUFFLE [RS_193]
+                                                  PartitionCols:_col1, _col2
+                                                  Select Operator [SEL_192] 
(rows=15992347 width=39)
+                                                    
Output:["_col0","_col1","_col2","_col3","_col4","_col5","_col6","_col7","_col8","_col9"]
+                                                    Filter Operator [FIL_191] 
(rows=15992347 width=243)
+                                                      
predicate:((ws_net_profit BETWEEN 100 AND 200 or ws_net_profit BETWEEN 150 AND 
300 or ws_net_profit BETWEEN 50 AND 250) and (ws_sales_price BETWEEN 100 AND 
150 or ws_sales_price BETWEEN 50 AND 100 or ws_sales_price BETWEEN 150 AND 200) 
and (ws_sold_date_sk BETWEEN DynamicValue(RS_27_date_dim_d_date_sk_min) AND 
DynamicValue(RS_27_date_dim_d_date_sk_max) and in_bloom_filter(ws_sold_date_sk, 
DynamicValue(RS_27_date_dim_d_date_sk_bloom_filter))) and ws_sold_date_sk is 
not null and ws_web_page_sk is not null)
+                                                      TableScan [TS_3] 
(rows=144002668 width=243)
+                                                        
default@web_sales,web_sales,Tbl:COMPLETE,Col:COMPLETE,Output:["ws_sold_date_sk","ws_item_sk","ws_web_page_sk","ws_order_number","ws_quantity","ws_sales_price","ws_net_profit"]
+                                                      <-Reducer 12 
[BROADCAST_EDGE] vectorized
+                                                        BROADCAST [RS_190]
+                                                          Group By Operator 
[GBY_189] (rows=1 width=12)
+                                                            
Output:["_col0","_col1","_col2"],aggregations:["min(VALUE._col0)","max(VALUE._col1)","bloom_filter(VALUE._col2,
 expectedEntries=1000000)"]
+                                                          <-Map 11 
[CUSTOM_SIMPLE_EDGE] vectorized
+                                                            SHUFFLE [RS_188]
+                                                              Group By 
Operator [GBY_187] (rows=1 width=12)
+                                                                
Output:["_col0","_col1","_col2"],aggregations:["min(_col0)","max(_col0)","bloom_filter(_col0,
 expectedEntries=1000000)"]
+                                                                Select 
Operator [SEL_186] (rows=652 width=4)
+                                                                  
Output:["_col0"]
+                                                                   Please 
refer to the previous Select Operator [SEL_184]
 

http://git-wip-us.apache.org/repos/asf/hive/blob/5553c59e/ql/src/test/results/clientpositive/perf/tez/constraints/query91.q.out
----------------------------------------------------------------------
diff --git 
a/ql/src/test/results/clientpositive/perf/tez/constraints/query91.q.out 
b/ql/src/test/results/clientpositive/perf/tez/constraints/query91.q.out
index 427bdd4..8e0790f 100644
--- a/ql/src/test/results/clientpositive/perf/tez/constraints/query91.q.out
+++ b/ql/src/test/results/clientpositive/perf/tez/constraints/query91.q.out
@@ -77,120 +77,120 @@ POSTHOOK: Output: hdfs://### HDFS PATH ###
 Plan optimized by CBO.
 
 Vertex dependency in root stage
-Reducer 11 <- Map 10 (SIMPLE_EDGE), Map 13 (SIMPLE_EDGE)
-Reducer 12 <- Map 14 (SIMPLE_EDGE), Reducer 11 (SIMPLE_EDGE)
-Reducer 2 <- Map 1 (SIMPLE_EDGE), Map 8 (SIMPLE_EDGE)
-Reducer 3 <- Map 9 (SIMPLE_EDGE), Reducer 2 (SIMPLE_EDGE)
+Reducer 12 <- Map 11 (SIMPLE_EDGE), Map 13 (SIMPLE_EDGE)
+Reducer 2 <- Map 1 (SIMPLE_EDGE), Map 9 (SIMPLE_EDGE)
+Reducer 3 <- Map 10 (SIMPLE_EDGE), Reducer 2 (SIMPLE_EDGE)
 Reducer 4 <- Reducer 12 (SIMPLE_EDGE), Reducer 3 (SIMPLE_EDGE)
-Reducer 5 <- Map 15 (SIMPLE_EDGE), Reducer 4 (SIMPLE_EDGE)
-Reducer 6 <- Reducer 5 (SIMPLE_EDGE)
+Reducer 5 <- Map 14 (SIMPLE_EDGE), Reducer 4 (SIMPLE_EDGE)
+Reducer 6 <- Map 15 (SIMPLE_EDGE), Reducer 5 (SIMPLE_EDGE)
 Reducer 7 <- Reducer 6 (SIMPLE_EDGE)
+Reducer 8 <- Reducer 7 (SIMPLE_EDGE)
 
 Stage-0
   Fetch Operator
     limit:-1
     Stage-1
-      Reducer 7 vectorized
-      File Output Operator [FS_168]
-        Select Operator [SEL_167] (rows=1 width=406)
+      Reducer 8 vectorized
+      File Output Operator [FS_170]
+        Select Operator [SEL_169] (rows=5219 width=406)
           Output:["_col0","_col1","_col2","_col3"]
-        <-Reducer 6 [SIMPLE_EDGE] vectorized
-          SHUFFLE [RS_166]
-            Select Operator [SEL_165] (rows=1 width=518)
+        <-Reducer 7 [SIMPLE_EDGE] vectorized
+          SHUFFLE [RS_168]
+            Select Operator [SEL_167] (rows=5219 width=518)
               Output:["_col0","_col1","_col2","_col4"]
-              Group By Operator [GBY_164] (rows=1 width=585)
+              Group By Operator [GBY_166] (rows=5219 width=585)
                 
Output:["_col0","_col1","_col2","_col3","_col4","_col5"],aggregations:["sum(VALUE._col0)"],keys:KEY._col0,
 KEY._col1, KEY._col2, KEY._col3, KEY._col4
-              <-Reducer 5 [SIMPLE_EDGE]
+              <-Reducer 6 [SIMPLE_EDGE]
                 SHUFFLE [RS_41]
                   PartitionCols:_col0, _col1, _col2, _col3, _col4
-                  Group By Operator [GBY_40] (rows=1 width=585)
-                    
Output:["_col0","_col1","_col2","_col3","_col4","_col5"],aggregations:["sum(_col11)"],keys:_col5,
 _col6, _col14, _col15, _col16
-                    Merge Join Operator [MERGEJOIN_143] (rows=10438 width=473)
-                      
Conds:RS_36._col2=RS_163._col0(Inner),Output:["_col5","_col6","_col11","_col14","_col15","_col16"]
+                  Group By Operator [GBY_40] (rows=5219 width=585)
+                    
Output:["_col0","_col1","_col2","_col3","_col4","_col5"],aggregations:["sum(_col11)"],keys:_col5,
 _col6, _col15, _col16, _col17
+                    Merge Join Operator [MERGEJOIN_145] (rows=10438 width=473)
+                      
Conds:RS_36._col10=RS_165._col0(Inner),Output:["_col5","_col6","_col11","_col15","_col16","_col17"]
                     <-Map 15 [SIMPLE_EDGE] vectorized
-                      SHUFFLE [RS_163]
+                      SHUFFLE [RS_165]
                         PartitionCols:_col0
-                        Select Operator [SEL_162] (rows=3600 width=4)
-                          Output:["_col0"]
-                          Filter Operator [FIL_161] (rows=3600 width=96)
-                            predicate:(hd_buy_potential like '0-500%')
-                            TableScan [TS_24] (rows=7200 width=96)
-                              
default@household_demographics,household_demographics,Tbl:COMPLETE,Col:COMPLETE,Output:["hd_demo_sk","hd_buy_potential"]
-                    <-Reducer 4 [SIMPLE_EDGE]
+                        Select Operator [SEL_164] (rows=60 width=298)
+                          Output:["_col0","_col1","_col2","_col3"]
+                          TableScan [TS_22] (rows=60 width=298)
+                            
default@call_center,call_center,Tbl:COMPLETE,Col:COMPLETE,Output:["cc_call_center_sk","cc_call_center_id","cc_name","cc_manager"]
+                    <-Reducer 5 [SIMPLE_EDGE]
                       SHUFFLE [RS_36]
-                        PartitionCols:_col2
-                        Merge Join Operator [MERGEJOIN_142] (rows=20876 
width=473)
-                          
Conds:RS_33._col0=RS_34._col1(Inner),Output:["_col2","_col5","_col6","_col11","_col14","_col15","_col16"]
-                        <-Reducer 12 [SIMPLE_EDGE]
-                          SHUFFLE [RS_34]
-                            PartitionCols:_col1
-                            Merge Join Operator [MERGEJOIN_141] (rows=657590 
width=312)
-                              
Conds:RS_20._col2=RS_160._col0(Inner),Output:["_col1","_col3","_col6","_col7","_col8"]
-                            <-Map 14 [SIMPLE_EDGE] vectorized
-                              SHUFFLE [RS_160]
-                                PartitionCols:_col0
-                                Select Operator [SEL_159] (rows=60 width=298)
-                                  Output:["_col0","_col1","_col2","_col3"]
-                                  TableScan [TS_15] (rows=60 width=298)
-                                    
default@call_center,call_center,Tbl:COMPLETE,Col:COMPLETE,Output:["cc_call_center_sk","cc_call_center_id","cc_name","cc_manager"]
-                            <-Reducer 11 [SIMPLE_EDGE]
-                              SHUFFLE [RS_20]
-                                PartitionCols:_col2
-                                Merge Join Operator [MERGEJOIN_140] 
(rows=657590 width=19)
-                                  
Conds:RS_155._col0=RS_158._col0(Inner),Output:["_col1","_col2","_col3"]
-                                <-Map 10 [SIMPLE_EDGE] vectorized
-                                  SHUFFLE [RS_155]
+                        PartitionCols:_col10
+                        Merge Join Operator [MERGEJOIN_144] (rows=10438 
width=179)
+                          
Conds:RS_33._col2=RS_163._col0(Inner),Output:["_col5","_col6","_col10","_col11"]
+                        <-Map 14 [SIMPLE_EDGE] vectorized
+                          SHUFFLE [RS_163]
+                            PartitionCols:_col0
+                            Select Operator [SEL_162] (rows=3600 width=4)
+                              Output:["_col0"]
+                              Filter Operator [FIL_161] (rows=3600 width=96)
+                                predicate:(hd_buy_potential like '0-500%')
+                                TableScan [TS_19] (rows=7200 width=96)
+                                  
default@household_demographics,household_demographics,Tbl:COMPLETE,Col:COMPLETE,Output:["hd_demo_sk","hd_buy_potential"]
+                        <-Reducer 4 [SIMPLE_EDGE]
+                          SHUFFLE [RS_33]
+                            PartitionCols:_col2
+                            Merge Join Operator [MERGEJOIN_143] (rows=20876 
width=179)
+                              
Conds:RS_30._col0=RS_31._col1(Inner),Output:["_col2","_col5","_col6","_col10","_col11"]
+                            <-Reducer 12 [SIMPLE_EDGE]
+                              SHUFFLE [RS_31]
+                                PartitionCols:_col1
+                                Merge Join Operator [MERGEJOIN_142] 
(rows=657590 width=19)
+                                  
Conds:RS_157._col0=RS_160._col0(Inner),Output:["_col1","_col2","_col3"]
+                                <-Map 11 [SIMPLE_EDGE] vectorized
+                                  SHUFFLE [RS_157]
                                     PartitionCols:_col0
-                                    Select Operator [SEL_154] (rows=27658583 
width=121)
+                                    Select Operator [SEL_156] (rows=27658583 
width=121)
                                       Output:["_col0","_col1","_col2","_col3"]
-                                      Filter Operator [FIL_153] (rows=27658583 
width=121)
+                                      Filter Operator [FIL_155] (rows=27658583 
width=121)
                                         predicate:(cr_call_center_sk is not 
null and cr_returned_date_sk is not null and cr_returning_customer_sk is not 
null)
                                         TableScan [TS_9] (rows=28798881 
width=121)
                                           
default@catalog_returns,catalog_returns,Tbl:COMPLETE,Col:COMPLETE,Output:["cr_returned_date_sk","cr_returning_customer_sk","cr_call_center_sk","cr_net_loss"]
                                 <-Map 13 [SIMPLE_EDGE] vectorized
-                                  SHUFFLE [RS_158]
+                                  SHUFFLE [RS_160]
                                     PartitionCols:_col0
-                                    Select Operator [SEL_157] (rows=50 width=4)
+                                    Select Operator [SEL_159] (rows=50 width=4)
                                       Output:["_col0"]
-                                      Filter Operator [FIL_156] (rows=50 
width=12)
+                                      Filter Operator [FIL_158] (rows=50 
width=12)
                                         predicate:((d_moy = 11) and (d_year = 
1999))
                                         TableScan [TS_12] (rows=73049 width=12)
                                           
default@date_dim,date_dim,Tbl:COMPLETE,Col:COMPLETE,Output:["d_date_sk","d_year","d_moy"]
-                        <-Reducer 3 [SIMPLE_EDGE]
-                          SHUFFLE [RS_33]
-                            PartitionCols:_col0
-                            Merge Join Operator [MERGEJOIN_139] (rows=479709 
width=183)
-                              
Conds:RS_30._col3=RS_152._col0(Inner),Output:["_col0","_col2","_col5","_col6"]
-                            <-Map 9 [SIMPLE_EDGE] vectorized
-                              SHUFFLE [RS_152]
-                                PartitionCols:_col0
-                                Select Operator [SEL_151] (rows=8000000 
width=4)
-                                  Output:["_col0"]
-                                  Filter Operator [FIL_150] (rows=8000000 
width=112)
-                                    predicate:(ca_gmt_offset = -7)
-                                    TableScan [TS_6] (rows=40000000 width=112)
-                                      
default@customer_address,customer_address,Tbl:COMPLETE,Col:COMPLETE,Output:["ca_address_sk","ca_gmt_offset"]
-                            <-Reducer 2 [SIMPLE_EDGE]
+                            <-Reducer 3 [SIMPLE_EDGE]
                               SHUFFLE [RS_30]
-                                PartitionCols:_col3
-                                Merge Join Operator [MERGEJOIN_138] 
(rows=2398543 width=187)
-                                  
Conds:RS_146._col1=RS_149._col0(Inner),Output:["_col0","_col2","_col3","_col5","_col6"]
-                                <-Map 1 [SIMPLE_EDGE] vectorized
-                                  SHUFFLE [RS_146]
-                                    PartitionCols:_col1
-                                    Select Operator [SEL_145] (rows=74500295 
width=15)
-                                      Output:["_col0","_col1","_col2","_col3"]
-                                      Filter Operator [FIL_144] (rows=74500295 
width=15)
-                                        predicate:(c_current_addr_sk is not 
null and c_current_cdemo_sk is not null and c_current_hdemo_sk is not null)
-                                        TableScan [TS_0] (rows=80000000 
width=15)
-                                          
default@customer,customer,Tbl:COMPLETE,Col:COMPLETE,Output:["c_customer_sk","c_current_cdemo_sk","c_current_hdemo_sk","c_current_addr_sk"]
-                                <-Map 8 [SIMPLE_EDGE] vectorized
-                                  SHUFFLE [RS_149]
+                                PartitionCols:_col0
+                                Merge Join Operator [MERGEJOIN_141] 
(rows=479709 width=183)
+                                  
Conds:RS_27._col3=RS_154._col0(Inner),Output:["_col0","_col2","_col5","_col6"]
+                                <-Map 10 [SIMPLE_EDGE] vectorized
+                                  SHUFFLE [RS_154]
                                     PartitionCols:_col0
-                                    Select Operator [SEL_148] (rows=59105 
width=183)
-                                      Output:["_col0","_col1","_col2"]
-                                      Filter Operator [FIL_147] (rows=59105 
width=183)
-                                        predicate:((cd_education_status) IN 
('Unknown', 'Advanced Degree') and (cd_marital_status) IN ('M', 'W') and 
(struct(cd_marital_status,cd_education_status)) IN (const 
struct('M','Unknown'), const struct('W','Advanced Degree')))
-                                        TableScan [TS_3] (rows=1861800 
width=183)
-                                          
default@customer_demographics,customer_demographics,Tbl:COMPLETE,Col:COMPLETE,Output:["cd_demo_sk","cd_marital_status","cd_education_status"]
+                                    Select Operator [SEL_153] (rows=8000000 
width=4)
+                                      Output:["_col0"]
+                                      Filter Operator [FIL_152] (rows=8000000 
width=112)
+                                        predicate:(ca_gmt_offset = -7)
+                                        TableScan [TS_6] (rows=40000000 
width=112)
+                                          
default@customer_address,customer_address,Tbl:COMPLETE,Col:COMPLETE,Output:["ca_address_sk","ca_gmt_offset"]
+                                <-Reducer 2 [SIMPLE_EDGE]
+                                  SHUFFLE [RS_27]
+                                    PartitionCols:_col3
+                                    Merge Join Operator [MERGEJOIN_140] 
(rows=2398543 width=187)
+                                      
Conds:RS_148._col1=RS_151._col0(Inner),Output:["_col0","_col2","_col3","_col5","_col6"]
+                                    <-Map 1 [SIMPLE_EDGE] vectorized
+                                      SHUFFLE [RS_148]
+                                        PartitionCols:_col1
+                                        Select Operator [SEL_147] 
(rows=74500295 width=15)
+                                          
Output:["_col0","_col1","_col2","_col3"]
+                                          Filter Operator [FIL_146] 
(rows=74500295 width=15)
+                                            predicate:(c_current_addr_sk is 
not null and c_current_cdemo_sk is not null and c_current_hdemo_sk is not null)
+                                            TableScan [TS_0] (rows=80000000 
width=15)
+                                              
default@customer,customer,Tbl:COMPLETE,Col:COMPLETE,Output:["c_customer_sk","c_current_cdemo_sk","c_current_hdemo_sk","c_current_addr_sk"]
+                                    <-Map 9 [SIMPLE_EDGE] vectorized
+                                      SHUFFLE [RS_151]
+                                        PartitionCols:_col0
+                                        Select Operator [SEL_150] (rows=59105 
width=183)
+                                          Output:["_col0","_col1","_col2"]
+                                          Filter Operator [FIL_149] 
(rows=59105 width=183)
+                                            predicate:((cd_education_status) 
IN ('Unknown', 'Advanced Degree') and (cd_marital_status) IN ('M', 'W') and 
(struct(cd_marital_status,cd_education_status)) IN (const 
struct('M','Unknown'), const struct('W','Advanced Degree')))
+                                            TableScan [TS_3] (rows=1861800 
width=183)
+                                              
default@customer_demographics,customer_demographics,Tbl:COMPLETE,Col:COMPLETE,Output:["cd_demo_sk","cd_marital_status","cd_education_status"]
 

http://git-wip-us.apache.org/repos/asf/hive/blob/5553c59e/ql/src/test/results/clientpositive/perf/tez/constraints/query99.q.out
----------------------------------------------------------------------
diff --git 
a/ql/src/test/results/clientpositive/perf/tez/constraints/query99.q.out 
b/ql/src/test/results/clientpositive/perf/tez/constraints/query99.q.out
index 9b8ebd2..e76bb8e 100644
--- a/ql/src/test/results/clientpositive/perf/tez/constraints/query99.q.out
+++ b/ql/src/test/results/clientpositive/perf/tez/constraints/query99.q.out
@@ -111,33 +111,33 @@ Stage-0
                   SHUFFLE [RS_26]
                     PartitionCols:_col0, _col1, _col2
                     Group By Operator [GBY_25] (rows=7739106 width=406)
-                      
Output:["_col0","_col1","_col2","_col3","_col4","_col5","_col6","_col7"],aggregations:["sum(_col4)","sum(_col5)","sum(_col6)","sum(_col7)","sum(_col8)"],keys:_col15,
 _col11, _col13
+                      
Output:["_col0","_col1","_col2","_col3","_col4","_col5","_col6","_col7"],aggregations:["sum(_col4)","sum(_col5)","sum(_col6)","sum(_col7)","sum(_col8)"],keys:_col13,
 _col11, _col15
                       Top N Key Operator [TNK_53] (rows=15478212 width=386)
-                        keys:_col15, _col11, _col13,sort order:+++,top n:100
+                        keys:_col13, _col11, _col15,sort order:+++,top n:100
                         Merge Join Operator [MERGEJOIN_97] (rows=15478212 
width=386)
-                          
Conds:RS_21._col3=RS_119._col0(Inner),Output:["_col4","_col5","_col6","_col7","_col8","_col11","_col13","_col15"]
+                          
Conds:RS_21._col1=RS_119._col0(Inner),Output:["_col4","_col5","_col6","_col7","_col8","_col11","_col13","_col15"]
                         <-Map 13 [SIMPLE_EDGE] vectorized
                           SHUFFLE [RS_119]
                             PartitionCols:_col0
-                            Select Operator [SEL_118] (rows=27 width=188)
+                            Select Operator [SEL_118] (rows=60 width=102)
                               Output:["_col0","_col1"]
-                              TableScan [TS_10] (rows=27 width=104)
-                                
default@warehouse,warehouse,Tbl:COMPLETE,Col:COMPLETE,Output:["w_warehouse_sk","w_warehouse_name"]
+                              TableScan [TS_10] (rows=60 width=102)
+                                
default@call_center,call_center,Tbl:COMPLETE,Col:COMPLETE,Output:["cc_call_center_sk","cc_name"]
                         <-Reducer 4 [SIMPLE_EDGE]
                           SHUFFLE [RS_21]
-                            PartitionCols:_col3
-                            Merge Join Operator [MERGEJOIN_96] (rows=15478212 
width=205)
-                              
Conds:RS_18._col1=RS_117._col0(Inner),Output:["_col3","_col4","_col5","_col6","_col7","_col8","_col11","_col13"]
+                            PartitionCols:_col1
+                            Merge Join Operator [MERGEJOIN_96] (rows=15478212 
width=291)
+                              
Conds:RS_18._col3=RS_117._col0(Inner),Output:["_col1","_col4","_col5","_col6","_col7","_col8","_col11","_col13"]
                             <-Map 12 [SIMPLE_EDGE] vectorized
                               SHUFFLE [RS_117]
                                 PartitionCols:_col0
-                                Select Operator [SEL_116] (rows=60 width=102)
+                                Select Operator [SEL_116] (rows=27 width=188)
                                   Output:["_col0","_col1"]
-                                  TableScan [TS_8] (rows=60 width=102)
-                                    
default@call_center,call_center,Tbl:COMPLETE,Col:COMPLETE,Output:["cc_call_center_sk","cc_name"]
+                                  TableScan [TS_8] (rows=27 width=104)
+                                    
default@warehouse,warehouse,Tbl:COMPLETE,Col:COMPLETE,Output:["w_warehouse_sk","w_warehouse_name"]
                             <-Reducer 3 [SIMPLE_EDGE]
                               SHUFFLE [RS_18]
-                                PartitionCols:_col1
+                                PartitionCols:_col3
                                 Merge Join Operator [MERGEJOIN_95] 
(rows=15478212 width=111)
                                   
Conds:RS_15._col2=RS_107._col0(Inner),Output:["_col1","_col3","_col4","_col5","_col6","_col7","_col8","_col11"]
                                 <-Map 10 [SIMPLE_EDGE] vectorized

Reply via email to