[MDEV-12221] Valgrind warnings on binlog_encryption tests (Conditional jump or move depends on uninitialised value) Created: 2017-03-09  Updated: 2017-06-14

Status: Confirmed
Project: MariaDB Server
Component/s: Encryption, Replication, Server
Affects Version/s: 10.1
Fix Version/s: 10.1

Type: Bug Priority: Major
Reporter: Elena Stepanova Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: None
Environment:

Debian Jessie



 Description   

perl ./mtr binlog_encryption.encrypted_slave,cbc,innodb_plugin,mix --valgrind

10.1 07d89fa59c1734b5a963943dcb93ade0c4e92e48

==8661== Thread 26:
==8661== Conditional jump or move depends on uninitialised value(s)
==8661==    at 0x915DD8: Log_event::read_log_event(char const*, unsigned int, char const**, Format_description_log_event const*, char) (log_event.cc:1571)
==8661==    by 0x915AFE: Log_event::read_log_event(st_io_cache*, st_mysql_mutex*, Format_description_log_event const*, char) (log_event.cc:1507)
==8661==    by 0x541765: next_event(rpl_group_info*, unsigned long long*) (slave.cc:6813)
==8661==    by 0x539412: exec_relay_log_event(THD*, Relay_log_info*, rpl_group_info*) (slave.cc:3732)
==8661==    by 0x53CCC7: handle_slave_sql (slave.cc:4969)
==8661==    by 0xA0CAF3: pfs_spawn_thread (pfs.cc:1860)
==8661==    by 0x4E3B063: start_thread (pthread_create.c:309)
==8661==    by 0x6A7D62C: clone (clone.S:111)

==8661== Conditional jump or move depends on uninitialised value(s)
==8661==    at 0x701E07: Relay_log_info::inc_group_relay_log_pos(unsigned long long, rpl_group_info*, bool) (rpl_rli.cc:1026)
==8661==    by 0x7026DA: Relay_log_info::stmt_done(unsigned long long, THD*, rpl_group_info*) (rpl_rli.cc:1335)
==8661==    by 0x9142FC: Log_event::do_update_pos(rpl_group_info*) (log_event.cc:989)
==8661==    by 0x91C70E: Format_description_log_event::do_update_pos(rpl_group_info*) (log_event.cc:5315)
==8661==    by 0x543397: Log_event::update_pos(rpl_group_info*) (log_event.h:1359)
==8661==    by 0x539006: apply_event_and_update_pos_apply(Log_event*, THD*, rpl_group_info*, int) (slave.cc:3508)
==8661==    by 0x5392B5: apply_event_and_update_pos(Log_event*, THD*, rpl_group_info*) (slave.cc:3591)
==8661==    by 0x539A9B: exec_relay_log_event(THD*, Relay_log_info*, rpl_group_info*) (slave.cc:3873)
==8661==    by 0x53CCC7: handle_slave_sql (slave.cc:4969)
==8661==    by 0xA0CAF3: pfs_spawn_thread (pfs.cc:1860)
==8661==    by 0x4E3B063: start_thread (pthread_create.c:309)
==8661==    by 0x6A7D62C: clone (clone.S:111)

==8661==    at 0x5C7985: Lex_input_stream::get_text(st_mysql_lex_string*, unsigned int, int, int) (sql_lex.cc:1021)
==8661==    by 0x5C97A4: lex_one_token(YYSTYPE*, THD*) (sql_lex.cc:1751)
==8661==    by 0x5C7F08: MYSQLlex(YYSTYPE*, THD*) (sql_lex.cc:1242)
==8661==    by 0x7AB54F: MYSQLparse(THD*) (sql_yacc.cc:19699)
==8661==    by 0x5EC5FE: parse_sql(THD*, Parser_state*, Object_creation_ctx*, bool) (sql_parse.cc:9318)
==8661==    by 0x5E83E0: mysql_parse(THD*, char*, unsigned int, Parser_state*) (sql_parse.cc:7295)
==8661==    by 0x91A89F: Query_log_event::do_apply_event(rpl_group_info*, char const*, unsigned int) (log_event.cc:4460)
==8661==    by 0x919A28: Query_log_event::do_apply_event(rpl_group_info*) (log_event.cc:4172)
==8661==    by 0x543336: Log_event::apply_event(rpl_group_info*) (log_event.h:1343)
==8661==    by 0x538E01: apply_event_and_update_pos_apply(Log_event*, THD*, rpl_group_info*, int) (slave.cc:3470)
==8661==    by 0x5392B5: apply_event_and_update_pos(Log_event*, THD*, rpl_group_info*) (slave.cc:3591)
==8661==    by 0x539A9B: exec_relay_log_event(THD*, Relay_log_info*, rpl_group_info*) (slave.cc:3873)
==8661==    by 0x53CCC7: handle_slave_sql (slave.cc:4969)
==8661==    by 0xA0CAF3: pfs_spawn_thread (pfs.cc:1860)
==8661==    by 0x4E3B063: start_thread (pthread_create.c:309)
==8661==    by 0x6A7D62C: clone (clone.S:111)

==8661== Conditional jump or move depends on uninitialised value(s)
==8661==    at 0x5492C18: pcre_exec (in /lib/x86_64-linux-gnu/libpcre.so.3.13.1)
==8661==    by 0x864B5B: Regexp_processor_pcre::pcre_exec_with_warn(real_pcre const*, pcre_extra const*, char const*, int, int, int, int*, int) (item_cmpfunc.cc:5439)
==8661==    by 0x864CD5: Regexp_processor_pcre::exec(String*, int, unsigned int) (item_cmpfunc.cc:5463)
==8661==    by 0x864E4D: Regexp_processor_pcre::exec(Item*, int, unsigned int) (item_cmpfunc.cc:5490)
==8661==    by 0x86507B: Item_func_regex::val_int() (item_cmpfunc.cc:5532)
==8661==    by 0x8423FE: Item::save_in_field(Field*, bool) (item.cc:6059)
==8661==    by 0x96F885: sp_eval_expr(THD*, Field*, Item**) (sp_head.cc:448)
==8661==    by 0x97CD77: sp_rcontext::set_variable(THD*, Field*, Item**) (sp_rcontext.cc:378)
==8661==    by 0x5A791F: sp_rcontext::set_variable(THD*, unsigned int, Item**) (sp_rcontext.h:201)
==8661==    by 0x59E2BF: my_var_sp::set(THD*, Item*) (sql_class.cc:3895)
==8661==    by 0x59E3FF: select_dumpvar::send_data(List<Item>&) (sql_class.cc:3918)
==8661==    by 0x61D122: JOIN::exec_inner() (sql_select.cc:2590)
==8661==    by 0x61CB94: JOIN::exec() (sql_select.cc:2511)
==8661==    by 0x6201FE: mysql_select(THD*, Item***, TABLE_LIST*, unsigned int, List<Item>&, Item*, unsigned int, st_order*, st_order*, Item*, st_order*, unsigned long 
long, select_result*, st_select_lex_unit*, st_select_lex*) (sql_select.cc:3445)
==8661==    by 0x615A57: handle_select(THD*, LEX*, select_result*, unsigned long) (sql_select.cc:384)
==8661==    by 0x5E4E52: execute_sqlcom_select(THD*, TABLE_LIST*) (sql_parse.cc:5920)

... and many, many more

Also endless

/data/src/10.1-valgrind/storage/innobase/page/page0cur.cc:999: 0xdaab8f5[8] undefined at 0
/data/src/10.1-valgrind/storage/innobase/page/page0cur.cc:1110: 0xebef6f5[13] undefined at 5
/data/src/10.1-valgrind/storage/innobase/include/log0log.ic:379: 0x176c18d0[8] undefined at 0
/data/src/10.1-valgrind/storage/innobase/row/row0sel.cc:2597: 0xeb38f1c[4] undefined at 0

One difference that I noticed between machines where it's reproducible (e.g. Jessie) and a machine where it is not (e.g. openSUSE 13.1) is the PCRE library:

openSUSE 13.1

libpcre.so.1 => /usr/lib64/libpcre.so.1
 
libpcrecpp0-32bit-8.37-2.4.1.x86_64
libpcre1-8.37-2.4.1.x86_64
pcre-devel-8.37-2.4.1.x86_64
libpcreposix0-8.37-2.4.1.x86_64
libpcre1-32bit-8.37-2.4.1.x86_64
libpcrecpp0-8.37-2.4.1.x86_64
libpcre16-0-8.37-2.4.1.x86_64

Jessie

libpcre.so.3 => /lib/x86_64-linux-gnu/libpcre.so.
 
ii  libpcre3:amd64                         2:8.35-3.3+deb8u4                    amd64        Perl 5 Compatible Regular Expression Library - runtime files
ii  libpcre3:i386                          2:8.35-3.3+deb8u4                    i386         Perl 5 Compatible Regular Expression Library - runtime files
ii  libpcre3-dev:amd64                     2:8.35-3.3+deb8u4                    amd64        Perl 5 Compatible Regular Expression Library - development files
ii  libpcrecpp0:amd64                      2:8.35-3.3+deb8u4                    amd64        Perl 5 Compatible Regular Expression Library - C++ runtime files

but I don't know if all other warnings grow from it, and even if they do, what we should do about this.


Generated at Thu Feb 08 07:56:02 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.