Uploaded image for project: 'IMPALA'
  1. IMPALA
  2. IMPALA-8069

crash in impala::Sorter::Run::Run

    XMLWordPrintableJSON

Details

    Description

      0  0x00007fd37c9b8428 in raise () from /lib/x86_64-linux-gnu/libc.so.6
      #1  0x00007fd37c9ba02a in abort () from /lib/x86_64-linux-gnu/libc.so.6
      #2  0x00007fd37fb7fe49 in ?? () from /usr/lib/jvm/java-8-openjdk-amd64/jre/lib/amd64/server/libjvm.so
      #3  0x00007fd37fd35387 in ?? () from /usr/lib/jvm/java-8-openjdk-amd64/jre/lib/amd64/server/libjvm.so
      #4  0x00007fd37fb8995f in JVM_handle_linux_signal () from /usr/lib/jvm/java-8-openjdk-amd64/jre/lib/amd64/server/libjvm.so
      #5  0x00007fd37fb7cf78 in ?? () from /usr/lib/jvm/java-8-openjdk-amd64/jre/lib/amd64/server/libjvm.so
      #6  <signal handler called>
      #7  0x0000000002723007 in impala::Sorter::Run::Run (this=0x13485200, parent=0xd3d8b00, sort_tuple_desc=0xf6dd320, initial_run=true) at /home/mikeb/Impala/be/src/runtime/sorter.cc:609
      #8  0x000000000272a3cb in impala::Sorter::Open (this=0xd3d8b00) at /home/mikeb/Impala/be/src/runtime/sorter.cc:1514
      #9  0x000000000237b186 in impala::SortNode::Open (this=0xd3d8840, state=0xffa1ba0) at /home/mikeb/Impala/be/src/exec/sort-node.cc:84
      #10 0x000000000239b44b in impala::AnalyticEvalNode::Open (this=0x100aba80, state=0xffa1ba0) at /home/mikeb/Impala/be/src/exec/analytic-eval-node.cc:182
      #11 0x0000000001f20cba in impala::FragmentInstanceState::Open (this=0xf5afd80) at /home/mikeb/Impala/be/src/runtime/fragment-instance-state.cc:304
      #12 0x0000000001f1deee in impala::FragmentInstanceState::Exec (this=0xf5afd80) at /home/mikeb/Impala/be/src/runtime/fragment-instance-state.cc:84
      #13 0x0000000001f2ea39 in impala::QueryState::ExecFInstance (this=0xea20000, fis=0xf5afd80) at /home/mikeb/Impala/be/src/runtime/query-state.cc:584
      #14 0x0000000001f2cd42 in impala::QueryState::<lambda()>::operator()(void) const (__closure=0x7fd2b1869ca8) at /home/mikeb/Impala/be/src/runtime/query-state.cc:493
      #15 0x0000000001f2f7e1 in boost::detail::function::void_function_obj_invoker0<impala::QueryState::StartFInstances()::<lambda()>, void>::invoke(boost::detail::function::function_buffer &) (
          function_obj_ptr=...) at /home/mikeb/Impala/toolchain/boost-1.57.0-p3/include/boost/function/function_template.hpp:153
      #16 0x0000000001d46c96 in boost::function0<void>::operator() (this=0x7fd2b1869ca0) at /home/mikeb/Impala/toolchain/boost-1.57.0-p3/include/boost/function/function_template.hpp:767
      #17 0x00000000021d4897 in impala::Thread::SuperviseThread(std::string const&, std::string const&, boost::function<void ()>, impala::ThreadDebugInfo const*, impala::Promise<long, (impala::PromiseMode)0>*) (name=..., category=..., functor=..., parent_thread_info=0x7fd2b206a950, thread_started=0x7fd2b20698f0) at /home/mikeb/Impala/be/src/util/thread.cc:359
      #18 0x00000000021dcbb7 in boost::_bi::list5<boost::_bi::value<std::string>, boost::_bi::value<std::string>, boost::_bi::value<boost::function<void ()> >, boost::_bi::value<impala::ThreadDebugInfo*>, boost::_bi::value<impala::Promise<long, (impala::PromiseMode)0>*> >::operator()<void (*)(std::string const&, std::string const&, boost::function<void ()>, impala::ThreadDebugInfo const*, impala::Promise<long, (impala::PromiseMode)0>*), boost::_bi::list0>(boost::_bi::type<void>, void (*&)(std::string const&, std::string const&, boost::function<void ()>, impala::ThreadDebugInfo const*, impala::Promise<long, (impala::PromiseMode)0>*), boost::_bi::list0&, int) (this=0xed511c0,
          f=@0xed511b8: 0x21d4530 <impala::Thread::SuperviseThread(std::string const&, std::string const&, boost::function<void ()>, impala::ThreadDebugInfo const*, impala::Promise<long, (impala::PromiseMode)0>*)>, a=...) at /home/mikeb/Impala/toolchain/boost-1.57.0-p3/include/boost/bind/bind.hpp:525
      #19 0x00000000021dcadb in boost::_bi::bind_t<void, void (*)(std::string const&, std::string const&, boost::function<void ()>, impala::ThreadDebugInfo const*, impala::Promise<long, (impala::PromiseMode)0>*), boost::_bi::list5<boost::_bi::value<std::string>, boost::_bi::value<std::string>, boost::_bi::value<boost::function<void ()> >, boost::_bi::value<impala::ThreadDebugInfo*>, boost::_bi::value<impala::Promise<long, (impala::PromiseMode)0>*> > >::operator()() (this=0xed511b8) at /home/mikeb/Impala/toolchain/boost-1.57.0-p3/include/boost/bind/bind_template.hpp:20
      #20 0x00000000021dca9e in boost::detail::thread_data<boost::_bi::bind_t<void, void (*)(std::string const&, std::string const&, boost::function<void ()>, impala::ThreadDebugInfo const*, impala::Promise<long, (impala::PromiseMode)0>*), boost::_bi::list5<boost::_bi::value<std::string>, boost::_bi::value<std::string>, boost::_bi::value<boost::function<void ()> >, boost::_bi::value<impala::ThreadDebugInfo*>, boost::_bi::value<impala::Promise<long, (impala::PromiseMode)0>*> > > >::run() (this=0xed51000)
          at /home/mikeb/Impala/toolchain/boost-1.57.0-p3/include/boost/thread/detail/thread.hpp:116
      #21 0x00000000036c17fa in thread_proxy ()
      #22 0x00007fd37cd546ba in start_thread () from /lib/x86_64-linux-gnu/libpthread.so.0
      #23 0x00007fd37ca8a41d in clone () from /lib/x86_64-linux-gnu/libc.so.6
      
       605 Sorter::Run::Run(Sorter* parent, TupleDescriptor* sort_tuple_desc, bool initial_run)
       606   : sorter_(parent),
       607     sort_tuple_desc_(sort_tuple_desc),
       608     sort_tuple_size_(sort_tuple_desc->byte_size()),
       609     page_capacity_(parent->page_len_ / sort_tuple_size_),
       610     has_var_len_slots_(sort_tuple_desc->HasVarlenSlots()),
       611     initial_run_(initial_run),
       612     is_pinned_(initial_run),
       613     is_finalized_(false),
       614     is_sorted_(!initial_run),
       615     num_tuples_(0) {}
      

      sort_tuple_size_ is 0:

      (gdb) f
      #7  0x0000000002723007 in impala::Sorter::Run::Run (this=0x13485200, parent=0xd3d8b00, sort_tuple_desc=0xf6dd320, initial_run=true) at /home/mikeb/Impala/be/src/runtime/sorter.cc:609
      609         page_capacity_(parent->page_len_ / sort_tuple_size_),
      (gdb) p sort_tuple_size_
      $3 = 0
      (gdb)
      

      The random query generator found this crash. A reproducing query is pretty simple:

      SELECT
      FIRST_VALUE(0) OVER (ORDER BY 0 ASC)
      FROM functional.alltypestiny
      

      Original query, FYI:

      USE tpch;
      SELECT
      COALESCE(COALESCE(a2.r_regionkey, a1.r_regionkey, a1.r_regionkey), a1.r_regionkey, a1.r_regionkey) AS int_col,
      a2.r_regionkey
      FROM region a1
      LEFT JOIN region a2 ON (a1.r_regionkey) = (a2.r_regionkey)
      UNION ALL
      SELECT
      GREATEST(-383.085779061, COALESCE(GREATEST(COALESCE(FIRST_VALUE(-150) OVER (ORDER BY 858.522977667 ASC), 260), -699), -915)) AS float_col,
      858.522977667 AS float_col_1
      FROM part a3
      

      Attachments

        Issue Links

          Activity

            People

              Paul.Rogers Paul Rogers
              mikeb Michael Brown
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: