Valgrind warning/crash in MRR with join_cache_level=8
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
MariaDB |
Fix Released
|
Critical
|
Igor Babaev |
Bug Description
The test case below produces the following warning:
==16327== Conditional jump or move depends on uninitialised value(s)
==16327== at 0x827B853: key_restore(
==16327== by 0x84BCF38: Mrr_ordered_
==16327== by 0x84BD5F2: Mrr_ordered_
==16327== by 0x84BD45E: Mrr_ordered_
==16327== by 0x84BDFFC: DsMrr_impl:
==16327== by 0x869B3BF: ha_innobase:
==16327== by 0x82F5325: JOIN_TAB_
==16327== by 0x82F3279: JOIN_CACHE:
==16327== by 0x82F2E72: JOIN_CACHE:
==16327== by 0x833D787: sub_select_
==16327== by 0x833D99F: sub_select(JOIN*, st_join_table*, bool) (sql_select.
==16327== by 0x833D48E: do_select(JOIN*, List<Item>*, st_table*, Procedure*) (sql_select.
==16327== by 0x83203A2: JOIN::exec() (sql_select.
==16327== by 0x8322529: mysql_select(THD*, Item***, TABLE_LIST*, unsigned int, List<Item>&, Item*, unsigned int, st_order*, st_order*, Item*, st_order*, un
signed long long, select_result*, st_select_
==16327== by 0x831A2FA: handle_select(THD*, st_lex*, select_result*, unsigned long) (sql_select.cc:283)
==16327== by 0x82B4A87: execute_
test case (further simplification was not possible for sporadic crashes):
--source include/
set session optimizer_
set session join_cache_level=8;
DROP TABLE IF EXISTS t1;
CREATE TABLE t1 ( col_int_key int(11), col_time_key time, col_varchar_key varchar(1), KEY (col_int_key), KEY (col_varchar_
INSERT IGNORE INTO t1 VALUES (7,'10:
DROP TABLE IF EXISTS t2;
CREATE TABLE t2 ( col_int_nokey int(11), col_int_key int(11), col_datetime_key datetime, col_datetime_nokey datetime, col_varchar_key varchar(1), col_varchar_nokey varchar(1), KEY (col_int_key), KEY (col_varchar_
INSERT IGNORE INTO t2 VALUES (150,62,'2008-01-03 10:33:32'
CREATE OR REPLACE ALGORITHM=MERGE VIEW v2 AS SELECT * FROM t2;
SELECT t1.col_time_key, t1.col_varchar_key
FROM
( v2 STRAIGHT_JOIN t1 ON
(t1.col_int_key = v2.col_int_key )
)
GROUP BY 1 , 2 ;
bzr version-info
revision-id: <email address hidden>
date: 2011-10-19 21:01:42 +0200
build-date: 2011-10-20 13:50:14 +0300
revno: 3242
branch-nick: maria-5.3
full optimizer switch: index_merge=
pushdown=
partial_
tal=on,
Changed in maria: | |
status: | New → Confirmed |
importance: | Undecided → Critical |
Changed in maria: | |
status: | Confirmed → In Progress |
Changed in maria: | |
status: | In Progress → Fix Committed |
Changed in maria: | |
status: | Fix Committed → Fix Released |
Also repeatable without views.