discuss-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Discuss-gnuradio] crashes, memory errors and valgrind


From: Patrick Strasser
Subject: [Discuss-gnuradio] crashes, memory errors and valgrind
Date: Sat, 02 Jun 2012 11:50:40 +0200
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.6) Gecko/20050602 Thunderbird/1.0.2 Mnenhy/0.7.2.0

Hello list,

I'm playing around with gqrx, an excellent example which great
standalone software can be built with gnuradio.

I'm running phirsch's rtlsdr fork, do not have a Funcube Dongle or USRP
at hand, but rather a Terratex NOXON DAB stick - 25€ part does the trick
fine enough for me ;-)

I'm running a self-compiled gnuradio rev3.6.0 on my Debian testing amd64
machine.

Sometime it crashes with messages like "glibc detected *** gqrx:
corrupted double-linked list". Firing up valgrind on it I find -besides
several uninitialized variables- messages of the kind:

==31294== Invalid read of size 8
==31294==    at 0x4F782AC: float_dotprod_sse (in
/usr/local/lib/libgnuradio-core-3.6.0.so.0.0.0)
[deleted some lines...]
==31294==  Address 0x1a211ba8 is 440 bytes inside a block of size 447
alloc'd
==31294==    at 0x402894D: malloc (in
/usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
==31294==    by 0x4FB3C5E: malloc16Align (in
/usr/local/lib/libgnuradio-core-3.6.0.so.0.0.0)
==31294==    by 0x4FB3CA9: calloc16Align (in
/usr/local/lib/libgnuradio-core-3.6.0.so.0.0.0)
==31294==    by 0x4F75E27: gr_fir_fff_simd::set_taps(std::vector<float,
std::allocator<float> > const&) (in
/usr/local/lib/libgnuradio-core-3.6.0.so.0.0.0)
[deleted some lines...]

Full trace of that error below, I can provide a full trace of a run if
needed.

Usually the program runs stable, but occasionally it crashes. I played
around with the internal bandwidth to get better FM reception - 75kHz is
quite narrow for FM reception. This change seems to trigger the problems
much faster. I hardly can change any parameters while running without a
crash.

I'm no expert, but it seems to me there is not enough memory allocated.
Maybe an off-by-one error? Did anyone see things like that or used
valgrind recently on gnuradio programs? What could I do to find out more
about this problem?

Regards

Patrick

---------------------------------------------------------

==31294== Invalid read of size 8
==31294==    at 0x4F782AC: float_dotprod_sse (in
/usr/local/lib/libgnuradio-core-3.6.0.so.0.0.0)
==31294==    by 0x4F8A27F:
gr_rational_resampler_base_fff::general_work(int, std::vector<int,
std::allocator<int> >&, std::vector<void const*, std::allocator<void
const*> >&, std::vector<void*, std::allocator<void*> >&) (in
/usr/local/lib/libgnuradio-core-3.6.0.so.0.0.0)
==31294==    by 0x4F45CBD: gr_block_executor::run_one_iteration() (in
/usr/local/lib/libgnuradio-core-3.6.0.so.0.0.0)
==31294==    by 0x4F65AA8:
gr_tpb_thread_body::gr_tpb_thread_body(boost::shared_ptr<gr_block>, int)
(in /usr/local/lib/libgnuradio-core-3.6.0.so.0.0.0)
==31294==    by 0x4F60645:
boost::detail::function::void_function_obj_invoker0<gruel::thread_body_wrapper<tpb_container>,
void>::invoke(boost::detail::function::function_buffer&) (in
/usr/local/lib/libgnuradio-core-3.6.0.so.0.0.0)
==31294==    by 0x52BBCCD:
boost::detail::thread_data<boost::function0<void> >::run() (in
/usr/local/lib/libgruel-3.6.0.so.0.0.0)
==31294==    by 0x81EA928: ??? (in /usr/lib/libboost_thread.so.1.49.0)
==31294==    by 0x6C08B4F: start_thread (pthread_create.c:304)
==31294==    by 0x76959DC: clone (clone.S:112)
==31294==  Address 0x1a211ba8 is 440 bytes inside a block of size 447
alloc'd
==31294==    at 0x402894D: malloc (in
/usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
==31294==    by 0x4FB3C5E: malloc16Align (in
/usr/local/lib/libgnuradio-core-3.6.0.so.0.0.0)
==31294==    by 0x4FB3CA9: calloc16Align (in
/usr/local/lib/libgnuradio-core-3.6.0.so.0.0.0)
==31294==    by 0x4F75E27: gr_fir_fff_simd::set_taps(std::vector<float,
std::allocator<float> > const&) (in
/usr/local/lib/libgnuradio-core-3.6.0.so.0.0.0)
==31294==    by 0x4F8A144:
gr_rational_resampler_base_fff::install_taps(std::vector<float,
std::allocator<float> > const&) (in
/usr/local/lib/libgnuradio-core-3.6.0.so.0.0.0)
==31294==    by 0x4F8A5B6:
gr_rational_resampler_base_fff::gr_rational_resampler_base_fff(unsigned
int, unsigned int, std::vector<float, std::allocator<float> > const&)
(in /usr/local/lib/libgnuradio-core-3.6.0.so.0.0.0)
==31294==    by 0x4F8A826: gr_make_rational_resampler_base_fff(unsigned
int, unsigned int, std::vector<float, std::allocator<float> > const&)
(in /usr/local/lib/libgnuradio-core-3.6.0.so.0.0.0)
==31294==    by 0x44A41D: resampler_ff::resampler_ff(unsigned int,
unsigned int) (resampler_ff.cpp:71)
==31294==    by 0x44A025: make_resampler_ff(unsigned int, unsigned int)
(resampler_ff.cpp:33)
==31294==    by 0x4141C9: receiver::receiver(std::string, std::string)
(receiver.cpp:80)
==31294==    by 0x41DBD9: MainWindow::MainWindow(QString, QWidget*)
(mainwindow.cpp:64)
==31294==    by 0x41D4D7: main (main.cpp:52)

-- 
Engineers motto: cheap, good, fast: choose any two
Patrick Strasser <patrick dot strasser at  tugraz dot at>
Student of Telematics, Graz Univ. of Technology, Austria




reply via email to

[Prev in Thread] Current Thread [Next in Thread]