Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Interlaced encoding causes crash #2

Open
JDarnley opened this issue Feb 12, 2018 · 0 comments
Open

Interlaced encoding causes crash #2

JDarnley opened this issue Feb 12, 2018 · 0 comments

Comments

@JDarnley
Copy link
Contributor

Trying to use interlaced encoding causes a segfault in the transform. The crash happens in all wavelets available, an example backtrace for haar is below.

Arch Linux, x86-64, kernel 4.9.78-1, Boost 1.66.0-1, gcc 7.2.1+20180116-1.

gdb backtrace:

GNU gdb (GDB) 8.0.1
Copyright (C) 2017 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-pc-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from ./testprogs/vc2encode...done.
(gdb) r
Starting program: /home/james/src/vc2hqencode/testprogs/vc2encode --interlace --threads=1 --wavelet=haar1
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/usr/lib/libthread_db.so.1".
INFO: Processor Features:
INFO:   SSE4.2 [ ]
INFO:   AVX    [ ]
INFO:   AVX2   [ ]
INFO: VC2Encoder.cpp:281: Configuring for 1 threads, 4 jobs

[New Thread 0x7ffff66da700 (LWP 24326)]

Thread 2 "vc2encode" received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0x7ffff66da700 (LWP 24326)]
Haar_transform_H_inplace_10P2<1, short> (_idata=0x0, istride=3840, _odata=_odata@entry=0x7ffff66d9cd0, ostride=1920, iwidth=1920, iheight=136, owidth=1920, oheight=136)
    at haar_transform.hpp:153
153           int32_t D   = (((int32_t)idata[y*istride + x]) - offset) << shift;
(gdb) bt
#0  Haar_transform_H_inplace_10P2<1, short> (_idata=0x0, istride=3840, _odata=_odata@entry=0x7ffff66d9cd0, ostride=1920, iwidth=1920, iheight=136, owidth=1920, oheight=136)
    at haar_transform.hpp:153
#1  0x000055555557da54 in VC2Encoder::Transform<short> (this=0x555555825570, _job=<optimized out>) at VC2Encoder.cpp:1016
#2  0x000055555557df54 in boost::_mfi::mf1<void, VC2Encoder, JobBase*>::operator() (a1=0x55555582d4c0, p=0x555555825570, this=<optimized out>)
    at /usr/include/boost/bind/mem_fn_template.hpp:165
#3  boost::_bi::list2<boost::_bi::value<VC2Encoder*>, boost::_bi::value<JobBase*> >::operator()<boost::_mfi::mf1<void, VC2Encoder, JobBase*>, boost::_bi::list0> (a=<synthetic pointer>...,
    f=<synthetic pointer>..., this=<synthetic pointer>) at /usr/include/boost/bind/bind.hpp:319
#4  boost::_bi::bind_t<void, boost::_mfi::mf1<void, VC2Encoder, JobBase*>, boost::_bi::list2<boost::_bi::value<VC2Encoder*>, boost::_bi::value<JobBase*> > >::operator() (
    this=<synthetic pointer>) at /usr/include/boost/bind/bind.hpp:1294
#5  boost::asio::asio_handler_invoke<boost::_bi::bind_t<void, boost::_mfi::mf1<void, VC2Encoder, JobBase*>, boost::_bi::list2<boost::_bi::value<VC2Encoder*>, boost::_bi::value<JobBase*> > > > (function=<synthetic pointer>...) at /usr/include/boost/asio/handler_invoke_hook.hpp:69
#6  boost_asio_handler_invoke_helpers::invoke<boost::_bi::bind_t<void, boost::_mfi::mf1<void, VC2Encoder, JobBase*>, boost::_bi::list2<boost::_bi::value<VC2Encoder*>, boost::_bi::value<JobBase*> > >, boost::_bi::bind_t<void, boost::_mfi::mf1<void, VC2Encoder, JobBase*>, boost::_bi::list2<boost::_bi::value<VC2Encoder*>, boost::_bi::value<JobBase*> > > > (
    context=<synthetic pointer>..., function=<synthetic pointer>...) at /usr/include/boost/asio/detail/handler_invoke_helpers.hpp:37
#7  boost::asio::detail::handler_work<boost::_bi::bind_t<void, boost::_mfi::mf1<void, VC2Encoder, JobBase*>, boost::_bi::list2<boost::_bi::value<VC2Encoder*>, boost::_bi::value<JobBase*> > >, boost::asio::system_executor>::complete<boost::_bi::bind_t<void, boost::_mfi::mf1<void, VC2Encoder, JobBase*>, boost::_bi::list2<boost::_bi::value<VC2Encoder*>, boost::_bi::value<JobBase*> > > > (this=<synthetic pointer>, handler=<synthetic pointer>..., function=<synthetic pointer>...) at /usr/include/boost/asio/detail/handler_work.hpp:82
#8  boost::asio::detail::completion_handler<boost::_bi::bind_t<void, boost::_mfi::mf1<void, VC2Encoder, JobBase*>, boost::_bi::list2<boost::_bi::value<VC2Encoder*>, boost::_bi::value<JobBase*> > > >::do_complete (owner=0x55555582d090, base=<optimized out>) at /usr/include/boost/asio/detail/completion_handler.hpp:70
#9  0x0000555555582dd9 in boost::asio::detail::scheduler_operation::complete (bytes_transferred=0, ec=..., owner=0x55555582d090, this=<optimized out>)
    at /usr/include/boost/asio/detail/scheduler_operation.hpp:40
#10 boost::asio::detail::scheduler::do_run_one (ec=..., this_thread=..., lock=..., this=0x55555582d090) at /usr/include/boost/asio/detail/impl/scheduler.ipp:401
#11 boost::asio::detail::scheduler::run (ec=..., this=0x55555582d090) at /usr/include/boost/asio/detail/impl/scheduler.ipp:154
#12 boost::asio::io_context::run (this=0x55555582cde8) at /usr/include/boost/asio/impl/io_context.ipp:62
#13 ThreadPool::_run (this=0x55555582cde0) at ThreadPool.hpp:132
#14 0x00007ffff79bf7bf in ?? () from /usr/lib/libboost_thread.so.1.66.0
#15 0x00007ffff738308c in start_thread () from /usr/lib/libpthread.so.0
#16 0x00007ffff67d0e7f in clone () from /usr/lib/libc.so.6
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant