Details
-
Bug
-
Status: Closed (View Workflow)
-
Critical
-
Resolution: Fixed
-
N/A
-
None
Description
By "forever" in the summary I mean that I have never seen it finish, the longest I waited before interrupting was ~1 hour.
The test uses all default server startup options, loads original data set from MDEV-28073 (xpo_full_testcase.sql), runs ANALYZE PERSISTENT FOR ALL on all tables, and executes EXPLAIN for a query structured identically to MDEV-28073 (minus a couple of last JOINs), but the tables and fields in the query are mixed up - that is, different tables and fields from the dataset appear in different JOIN positions and conditions. The exact query will be provided.
A slight abnormality of this particular query is that one of ON conditions compares a datetime field to a string literal (not convertible into a proper date time), and thus produces Truncated incorrect datetime value warning (ER_TRUNCATED_WRONG_VALUE). I'm not sure whether it's a decisive factor for the problem, but it's possible. Except for this condition, the query is identical to MDEV-28928.
The query was executed with EXPLAIN FORMAT=JSON on several different versions/builds for comparison. All builds are non-debug.
preview-10.10-optimizer f332260c98 |
| 4 | root | localhost:36260 | test | Query | 590 | Statistics | EXPLAIN FORMAT=JSON SELECT * FROM ((((((((((((((((
|
...
|
It looks the same with optimizer_prune_level=2 (default) and 1.
preview-10.10-optimizer, MDEV-28852 baseline (07a31de109) |
MariaDB [test]> EXPLAIN FORMAT=JSON SELECT * FROM ((((((((((((((((
|
...
|
1 row in set, 1 warning (36.832 sec)
|
10.6 main 0e4cf497 |
MariaDB [test]> EXPLAIN FORMAT=JSON SELECT * FROM ((((((((((((((((
|
...
|
1 row in set, 1 warning (9.314 sec)
|
Attachments
Issue Links
- is caused by
-
MDEV-28928 Plan selection takes 2+ times longer than before MDEV-28852
-
- Closed
-
- relates to
-
MDEV-28852 Improve optimization of joins with many tables, including eq_ref tables
-
- Closed
-
Activity
Field | Original Value | New Value |
---|---|---|
Link |
This issue is caused by |
Assignee | Elena Stepanova [ elenst ] | Sergei Petrunia [ psergey ] |
Attachment | chart1-best-extensions-counts.png [ 64397 ] |
Attachment | chart2-best-extensions-grows.png [ 64398 ] |
Attachment | chart03-reasons-for-not-pruning.png [ 64404 ] |
Attachment | chart04-improved-pruning.png [ 64420 ] |
Attachment | chart04-pruning-in-table0.png [ 64440 ] |
Attachment | chart05-improved-pruning-v3-bap.png [ 64444 ] |
Attachment | chart06-improved-pruning-v3.png [ 64445 ] |
Attachment | pruning-v3-log.txt [ 64446 ] |
Attachment | psergey-mdev28929-improved-pruning-v3.diff [ 64447 ] |
Attachment | pruning-v3-log.txt [ 64446 ] |
Attachment | slide01.png [ 64460 ] |
Link |
This issue relates to |
Fix Version/s | 10.10.0 [ 27912 ] | |
Fix Version/s | 10.10 [ 27530 ] | |
Resolution | Fixed [ 1 ] | |
Status | Open [ 1 ] | Closed [ 6 ] |
Fix Version/s | 10.10.1 [ 27913 ] | |
Fix Version/s | 10.10.0 [ 27912 ] |