Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-33963

[Draft] runtime error: member access within address 0x... which does not point to an object of type 'Field'

    XMLWordPrintable

Details

    Description

      Possibly fails on earlier versions too. Needs a test case, cleaning, etc. Can be another representations of an existing bug, especially given the presence of Multiupdate_prelocking_strategy.

      modified admin.yy attached (also fails with the unmodified one, but this way it's a bit faster)

      randgen 306ad53f19f1e73b58174e3e99d3570d4ba00ce1

      perl ./run.pl --compatibility=110599 --filter=conf/ff/restrict_dynamic_vars.ff  --grammar=conf/yy/signal_resignal.yy --engine=InnoDB  --scenario=Standard  --variator=ExecuteAsPreparedTwice  --grammar=admin.yy --filter=conf/ff/optimize.ff  --queries=1000000 --reporters=Backtrace,Deadlock,MemoryUsage,FeatureUsage --mysqld=--plugin-maturity=experimental --duration=200 --mysqld=--max-statement-time=20 --mysqld=--lock-wait-timeout=10 --mysqld=--innodb-lock-wait-timeout=5 --threads=4 --gendata=conf/zz/oltp.zz --gendata=simple  --base-port=14000 --basedir=/data/bld/11.5-ubsan --vardir=/dev/shm/var2 --seed=1713747363
      

      11.5 ubsan 73ed0a23ebeba96d777b768cf79a290f6b4ea2e8

      /data/bld/11.5-ubsan/sql/item.cc:3504:14: runtime error: member access within address 0x7f62d8142f18 which does not point to an object of type 'Field'
      0x7f62d8142f18: note: object has invalid vptr
       8f 8f 8f 8f  8f 8f 8f 8f 8f 8f 8f 8f  8f 8f 8f 8f 8f 8f 8f 8f  8f 8f 8f 8f 8f 8f 8f 8f  8f 8f 8f 8f
                    ^~~~~~~~~~~~~~~~~~~~~~~
                    invalid vptr
      240422 15:29:07 [ERROR] mysqld got signal 7 ;
       
      #4  <signal handler called>
      #5  0x000055cfe00483aa in Item_field::used_tables (this=0x7f62d83e0318) at /data/bld/11.5-ubsan/sql/item.cc:3504
      #6  0x000055cfdf04c4f0 in setup_fields (thd=thd@entry=0x7f62d8000d58, ref_pointer_array=..., fields=..., column_usage=column_usage@entry=MARK_COLUMNS_WRITE, sum_func_list=sum_func_list@entry=0x0, pre_fix=0x0, allow_sum_func=false) at /data/bld/11.5-ubsan/sql/sql_base.cc:8095
      #7  0x000055cfdf648f31 in setup_fields_with_no_wrap (thd=thd@entry=0x7f62d8000d58, ref_pointer_array=..., item=..., column_usage=column_usage@entry=MARK_COLUMNS_WRITE, sum_func_list=sum_func_list@entry=0x0, allow_sum_func=<optimized out>) at /data/bld/11.5-ubsan/sql/sql_base.h:392
      #8  0x000055cfdf629198 in Multiupdate_prelocking_strategy::handle_end (this=0x7f62d83e1548, thd=0x7f62d8000d58) at /data/bld/11.5-ubsan/sql/sql_array.h:38
      #9  0x000055cfdf02e973 in open_tables (thd=thd@entry=0x7f62d8000d58, options=..., start=start@entry=0x7f62dfffd368, counter=counter@entry=0x7f62d83e1528, flags=flags@entry=512, prelocking_strategy=prelocking_strategy@entry=0x7f62d83e1548) at /data/bld/11.5-ubsan/sql/sql_base.cc:4765
      #10 0x000055cfdf032768 in open_tables (prelocking_strategy=0x7f62d83e1548, flags=512, counter=0x7f62d83e1528, tables=0x7f62dfffd368, thd=0x7f62d8000d58) at /data/bld/11.5-ubsan/sql/sql_base.h:271
      #11 open_tables_for_query (thd=thd@entry=0x7f62d8000d58, tables=<optimized out>, table_count=table_count@entry=0x7f62d83e1528, flags=flags@entry=0, prelocking_strategy=prelocking_strategy@entry=0x7f62d83e1548) at /data/bld/11.5-ubsan/sql/sql_base.cc:5765
      #12 0x000055cfdf35dd44 in Sql_cmd_dml::prepare (this=0x7f62d83e1510, thd=0x7f62d8000d58) at /data/bld/11.5-ubsan/sql/sql_select.cc:33488
      #13 0x000055cfdf2f9394 in check_prepared_statement (stmt=stmt@entry=0x7f62dfffd820) at /data/bld/11.5-ubsan/sql/sql_prepare.cc:2290
      #14 0x000055cfdf305a08 in Prepared_statement::prepare (this=this@entry=0x7f62dfffd820, packet=<optimized out>, packet_len=<optimized out>) at /data/bld/11.5-ubsan/sql/sql_prepare.cc:4244
      #15 0x000055cfdf30c023 in Prepared_statement::reprepare (this=this@entry=0x7f62ec0699a8) at /data/bld/11.5-ubsan/sql/sql_prepare.cc:4780
      #16 0x000055cfdf31a6ac in Prepared_statement::execute_loop (this=this@entry=0x7f62ec0699a8, expanded_query=expanded_query@entry=0x7f62dfffddc0, open_cursor=open_cursor@entry=false, packet=packet@entry=0x0, packet_end=packet_end@entry=0x0) at /data/bld/11.5-ubsan/sql/sql_prepare.cc:4474
      #17 0x000055cfdf31b124 in mysql_sql_stmt_execute (thd=thd@entry=0x7f62d8000d58) at /data/bld/11.5-ubsan/sql/sql_prepare.cc:3480
      #18 0x000055cfdf2700b9 in mysql_execute_command (thd=thd@entry=0x7f62d8000d58, is_called_from_prepared_stmt=is_called_from_prepared_stmt@entry=false) at /data/bld/11.5-ubsan/sql/sql_parse.cc:3958
      #19 0x000055cfdf284922 in mysql_parse (thd=thd@entry=0x7f62d8000d58, rawbuf=<optimized out>, length=<optimized out>, parser_state=parser_state@entry=0x7f62dfffe440) at /data/bld/11.5-ubsan/sql/sql_parse.cc:7815
      #20 0x000055cfdf28b275 in dispatch_command (command=command@entry=COM_QUERY, thd=thd@entry=0x7f62d8000d58, packet=packet@entry=0x7f62d800b1d9 "/* WRK-4 QNO 14856 */ EXECUTE /* RESULTSETS_NOT_COMPARABLE */ stmt_ExecuteAsPreparedTwice_2560005", packet_length=packet_length@entry=97, blocking=blocking@entry=true) at /data/bld/11.5-ubsan/sql/sql_parse.cc:1892
      #21 0x000055cfdf29385e in do_command (thd=0x7f62d8000d58, blocking=blocking@entry=true) at /data/bld/11.5-ubsan/sql/sql_parse.cc:1405
      #22 0x000055cfdf77f1f8 in do_handle_one_connection (connect=<optimized out>, connect@entry=0x55cfe554cdd8, put_in_cache=put_in_cache@entry=true) at /data/bld/11.5-ubsan/sql/sql_connect.cc:1445
      #23 0x000055cfdf7800a2 in handle_one_connection (arg=0x55cfe554cdd8) at /data/bld/11.5-ubsan/sql/sql_connect.cc:1347
      #24 0x000055cfe0908bf5 in pfs_spawn_thread (arg=0x55cfe554ce48) at /data/bld/11.5-ubsan/storage/perfschema/pfs.cc:2201
      #25 0x00007f63576a8044 in start_thread (arg=<optimized out>) at ./nptl/pthread_create.c:442
      
      

      Attachments

        Activity

          People

            elenst Elena Stepanova
            elenst Elena Stepanova
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:

              Git Integration

                Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.