[testsfail] Process.* (memory leak in libhybris generated when probing android platforms)

Bug #1602199 reported by Alan Griffiths on 2016-07-12
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Fix Released
Kevin DuBois
Fix Released
Kevin Dubois
mir (Ubuntu)

Bug Description


09:10:14 15: [ FAILED ] Process.a_main_fn_is_executed
09:10:14 15: [ FAILED ] Process.a_successful_exit_function_succeeds


09:06:54 17: [ FAILED ] Process.a_main_fn_is_executed
09:06:54 17: [ FAILED ] Process.a_successful_exit_function_succeeds

I can only imagine the build agent got no CPU for so long that wait_for_termination() timed out.

Related branches

tags: added: testsfail
Kevin DuBois (kdub) wrote :

iirc, Process* depends on the success of previous forks() (a bug in and of itself), but is not the root cause.

The cause seems to be a new libhybris release, which introduced a leak in the hw_get_module function. This function is used in platform probing, so it generates an error in valgrind.

unfortunately, valgrind seems to get confused about where this leak happens:
==8558== 192 bytes in 1 blocks are definitely lost in loss record 246 of 271
==8558== at 0x4C2DB8F: malloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
==8558== by 0xB56CE27: doc src
==8558== by 0xB56CFFB: doc src
==8558== by 0xB56C677: doc src
==8558== by 0xB77F59A: doc src
==8558== by 0xB77F97C: doc src
==8558== by 0xB77FC5E: doc src
==8558== by 0xB3697A8: doc src
==8558== by 0xAEB9030: std::_Tuple_impl<1ul, mir::ModuleDeleter<mir::test::doubles::NullPlatformIpcOperations> >::~_Tuple_impl() (tuple:339)
==8558== by 0x70469F: mir::graphics::module_for_device(std::vector<std::shared_ptr<mir::SharedLibrary>, std::allocator<std::shared_ptr<mir::SharedLibrary> > > const&, mir::options::ProgramOption const&) (platform_probe.cpp:38)

so I havent been able to come up with a suppression about it yet (which is the real fix)

Kevin DuBois (kdub) wrote :

oh, also, I suspect the reason that this was not reproducible was that only X+O systems would have the new libhybris, and would be the only ones with the leak.

Kevin DuBois (kdub) on 2016-07-14
Changed in mir:
importance: Undecided → High
assignee: nobody → Kevin DuBois (kdub)
milestone: none → 0.24.0
status: New → In Progress
Changed in mir:
status: In Progress → Fix Committed
milestone: 0.24.0 → 0.25.0
summary: - [testsfail] Process.*
+ [testsfail] Process.* (memory leak in libhybris generated when probing
+ android platforms)
Kevin DuBois (kdub) on 2016-07-20
Changed in mir:
milestone: 0.25.0 → 0.24.0
no longer affects: mir/0.24
Daniel van Vugt (vanvugt) wrote :

Fix committed to lp:mir/0.23 at revision 3530, scheduled for release in Mir 0.23.5

Daniel van Vugt (vanvugt) wrote :

This bug was fixed in the package mir - 0.23.5+16.10.20160729-0ubuntu1

Changed in mir (Ubuntu):
status: New → Fix Released
Changed in mir:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers