Commit Graph

104 Commits

Author SHA1 Message Date
1f0245a821 planner: Revert tidb_allow_mpp modification for downgrade compatibility and add warnings for enforce mpp. (#25302) 2021-06-11 10:28:35 +08:00
cad482c036 planner/core: remove the union branch with dual table. (#25218) 2021-06-08 19:46:28 +08:00
a7f3c4d8bd planner/core: change agg cost factor (#25210) 2021-06-08 15:44:28 +08:00
64b469623c planner/core: support limit push down (#24757) 2021-06-04 16:56:28 +08:00
b07942836f planner: fix a panic caused by sinking a Limit with inlined Proj into IndexLookUp when accessing a partition table (#25063) 2021-06-04 13:54:27 +08:00
49cd57174b session, planner: Add a factor getter for networkFactor/scanFactor/descScanFactor/seekFactor (#25046) 2021-06-03 16:50:27 +08:00
52e89cb8bf planner/core: support union all for mpp. (#24287) 2021-06-02 14:15:38 +08:00
ec618f1619 planner: support set tidb_allow_mpp to 2 or ENFORCE to enforce use mpp mode. (#24516) 2021-05-12 18:05:40 +08:00
0859a3c029 planner: refactor Converting Partition Keys for shuffle hash join (#24456) 2021-05-08 17:40:41 +08:00
e79fa8c6b6 planner: let CopTiFlashConcurrencyFactor inflence the cost of whole plan (#24157) 2021-04-28 16:43:56 +08:00
05bb31b811 planner/core: push down topn to mpp (#24081) 2021-04-19 12:49:52 +08:00
7d5fe41470 planner: support explain verbose mode (#23926) 2021-04-15 18:23:53 +08:00
50ea46ccb0 planner: append common handle columns into the schema of index merge table plan (#23933) 2021-04-14 20:27:52 +08:00
c2d5bef4e4 planner: make sure that join key type are always the same for mpp join (#23930) 2021-04-12 19:55:50 +08:00
008b91b12b planner: fix "can't find column" when projection wrongly added above table reader after agg pushed down (#23804)
* add test and comments
Co-authored-by: Ti Chi Robot <71242396+ti-chi-bot@users.noreply.github.com>
2021-04-01 23:42:17 +08:00
c660cee89b planner/core: fix a bug during add cast for decimal join key (#23723) 2021-03-31 17:54:26 +08:00
bc07307ec9 planner: fix bug that mpp avg will throw column index out of bound error (#23604) 2021-03-27 15:35:23 +08:00
fe250b9efb planner: fine grained collation control for mpp plan (#23584) 2021-03-26 18:31:23 +08:00
b11c71d23e MPP: fix 2-phase agg chose wrong partition column during planning (#23557) 2021-03-26 17:49:23 +08:00
a909037110 planner/core: inject project for tiflash agg (#23480) 2021-03-26 12:31:23 +08:00
40b92181d0 planner/core: convert decimal type for mpp join before shuffling. (#23191)
* planner: convert decimal type for mpp join before shuffling.

* fix bug and add code

* add some comments

* fix typo

* fix test

* add test and fix

* address comments

* add more tests

* address comments

* address comments

* address comments

* address comments

* add tests

* refine test

Co-authored-by: Ti Chi Robot <71242396+ti-chi-bot@users.noreply.github.com>
2021-03-26 00:16:58 +08:00
f6a61bc915 plan/core: support mpp group by expressions. (#23133)
* planner/core: make mpp support grouping by expressions

* add tests

* fix typo

* fix

* fix test

Co-authored-by: Ti Chi Robot <71242396+ti-chi-bot@users.noreply.github.com>
2021-03-10 17:06:15 +08:00
50aec2b2d2 planner: enable column pruning for common handle (#22940) 2021-03-04 14:42:54 +08:00
3ad7f40140 expression: Add warning info for exprs that can not be pushed to storage layer (#22713) 2021-02-20 10:41:57 +08:00
6d53dda29d plan, mpp: refine the precision of avg(decimal) & avg(null) for mpp (#22668) 2021-02-04 18:58:15 +08:00
7b79af93d7 planner: fix in-compatibility issues between TiDB agg and TiFlash agg in MPP mode (#22537) 2021-01-27 16:03:32 +08:00
e2540d4ec0 planner: Shuffle hash agg (#21842) 2021-01-22 11:49:30 +08:00
dae6e4935b planner/core: push selection operator to mpp task (#22343) 2021-01-11 17:51:58 +08:00
6e98d18e94 planner: push down projection for tiflash (#21459) 2021-01-07 11:41:44 +08:00
5e67a597cc planner, store/tikv, executor:Support shuffled hash join and refine codes (#20894) 2020-12-28 15:14:15 +08:00
77572f873d planner: do not push down the aggregation function with correlated column (#21453) 2020-12-08 10:54:24 +08:00
e33b37789c planner: add projection if expand virtual generated column (#20478)
Signed-off-by: wjhuang2016 <huangwenjun1997@gmail.com>
2020-12-03 21:42:49 +08:00
76c1d28af9 planner: support complex join in broadcast join (#20196) 2020-11-05 16:29:35 +08:00
aa2b83210d planner: make pushdown limit use its child schema (#20807) 2020-11-04 15:58:34 +08:00
369c12f779 [planner, executor, kv]: refine and extract mpp codes to the right place (#20691) 2020-11-02 14:30:47 +08:00
b1b1da22e5 planner: fix wrong argument for split aggregation (#20474) 2020-10-29 15:08:42 +08:00
e52cb3714e planner: Do not pushdown unsupported function to tiflash in TopN operator (#19363)
Co-authored-by: ti-srebot <66930949+ti-srebot@users.noreply.github.com>
2020-08-25 17:20:18 +08:00
977449f8b0 planner: fix a bug that can't find column in indexLookupJoin with virtual generated column (#18516) 2020-08-25 16:09:31 +08:00
3ac0baf61c *: fix unable prune problem caused by mismatch column infos (#19391) 2020-08-25 12:24:48 +08:00
4e829aaee7 planner,executor: fix index merge for partition table (#18940)
Co-authored-by: ti-srebot <66930949+ti-srebot@users.noreply.github.com>
2020-08-04 20:38:17 +08:00
5dd7cd8553 planner/core: implement Explain for the new partition table (#18834)
Co-authored-by: lysu <sulifx@gmail.com>
2020-07-30 15:37:02 +08:00
a1dc4381c5 planner,executor: implement PartitionTable executor for the three reader (#18823) 2020-07-30 11:00:55 +08:00
29178dfa8d planner, executor: support broadcast join for tiflash engine. (#17232)
* support batch cop for tiflash

* support batch cop

* support join push down to tiflash

* refine

* change pb

* push join

* fix

* add hint

* refine hint

* add ranges

* fix

* fix

* fix push down

* fix index

* enable distsql for join

* add a session var to disable/enable broadcast join

* fix bug

* fix bug

* tiny fix

* enable cast decimal pushdown to tiflash

* fix

* fix bc join bug

* make broadcast plan stable

* refine code

* fix bug

* basic support for multi table broadcast join

* fix bug

* basic cbo for broadcast join

* improve

* fix bug

* remote useless code

* add tests

* pass unit tests

* refine code

* support execute summary info for broadcast join

* fix bug in explain for broadcast join

* format code

* remove un-needed code

* fix make dev

* address comments

* Hanfei/join merge (#7)

* enable exec details for batch cop

* format code

* fix test

* change tidb_opt_broadcast_join to global vars

* Ban cartesian join to be pushed down to TiFlash (#8)

* merge master (#10)

* merge master

* fix bug

* fix bug

* fix ut

* check session var conflict

* Add perfer local hint for broadcast join (#12)

* update

* remove useless code

* remove useless code

* update parser

* add test for prefer local join

* use bcj_local

* update go.mod

* refine planner

* refine comments

* fix make dev

* fix make dev

* update parser

* address comments

* fix make dev

* disable broadcast join when new collation is enabled

* Update planner/core/exhaust_physical_plans.go

Co-authored-by: Zhuomin(Charming) Liu <lzmhhh123@gmail.com>

* address comments

* fix

* address comments

* fix tests

* address comments

Co-authored-by: xufei <xufeixw@mail.ustc.edu.cn>
Co-authored-by: xufei <xufei@pingcap.com>
Co-authored-by: 虎 <ichneumon.hu@foxmail.com>
Co-authored-by: Zhuomin(Charming) Liu <lzmhhh123@gmail.com>
2020-07-27 12:41:36 +08:00
a6971dd685 *: support 'admin check table' on clustered index table (#18346) 2020-07-14 15:59:37 +08:00
daad2699dd *: support clustered index for index join (#18204) 2020-07-01 16:15:51 +08:00
5250f7f53f *: support clustered index in double read (#18127) 2020-06-23 15:33:38 +08:00
c98514e751 executor: unify executor concurrency (#16999) 2020-06-22 17:39:32 +08:00
978370f7cb executor: add new agg function APPROX_COUNT_DISTINCT (#17175) 2020-06-18 22:00:14 +08:00
7ebcc20398 executor: support GROUP_CONCAT(ORDER BY) (#16591) 2020-05-06 18:41:22 +08:00
8f000fc353 planner: push avg & distinct functions across union (#16344) 2020-04-15 18:07:37 +08:00