
kaffeetisch at gmx
Mar 21, 2012, 3:12 PM
Post #1 of 4
(95 views)
Permalink
|
|
5.15.9 breaks Glib (was: Re: 5.15.8: Global destruction phase slow?)
|
|
With perl 5.15.9 (and blead) multiple of Glib's tests segfault. This reproduces the issue: use Glib; my $obj = Glib::Object->new; $obj->{key} = 'val'; gdb says: Program received signal SIGSEGV, Segmentation fault. 0x080ed041 in Perl_mg_clear (my_perl=0x81fa008, sv=0x81fe3d0) at mg.c:376 376 if (vtbl && vtbl->svt_clear) (gdb) bt #0 0x080ed041 in Perl_mg_clear (my_perl=0x81fa008, sv=0x81fe3d0) at mg.c:376 #1 0x08107264 in Perl_hv_undef_flags (my_perl=0x81fa008, hv=0x81fe3d0, flags=2) at hv.c:1872 #2 0x08122976 in Perl_sv_clear (my_perl=0x81fa008, orig_sv=0x81fe3d0) at sv.c:6294 #3 0x08123146 in Perl_sv_free2 (my_perl=0x81fa008, sv=0x81fe3d0) at sv.c:6506 #4 0x08129a87 in Perl_sv_unref_flags (my_perl=0x696c6174, ref=0x8217270, flags=1) at sv.c:9623 #5 0x0811f776 in Perl_sv_force_normal_flags (my_perl=0x81fa008, sv=0x8217270, flags=1) at sv.c:4834 #6 0x0814f6e9 in Perl_leave_scope (my_perl=0x81fa008, base=0) at scope.c:914 #7 0x0814d1ff in Perl_pop_scope (my_perl=0x696c6174) at scope.c:110 #8 0x08158155 in Perl_pp_leave (my_perl=0x81fa008) at pp_ctl.c:2152 #9 0x0810c4e7 in Perl_runops_standard (my_perl=0x81fa008) at run.c:41 #10 0x0807d373 in S_run_body (my_perl=0x81fa008, oldscope=1) at perl.c:2400 #11 0x0807ce5b in perl_run (my_perl=0x81fa008) at perl.c:2318 #12 0x0805d96d in main (argc=2, argv=0xbffff594, env=0xbffff5a0) at perlmain.c:120 valgrind says: ==26758== Conditional jump or move depends on uninitialised value(s) ==26758== at 0x80ED06B: Perl_mg_clear (mg.c:370) ==26758== by 0x8107263: Perl_hv_undef_flags (hv.c:1872) ==26758== by 0x8122975: Perl_sv_clear (sv.c:6294) ==26758== by 0x8123145: Perl_sv_free2 (sv.c:6506) ==26758== by 0x8129A86: Perl_sv_unref_flags (sv.c:9623) ==26758== by 0x811F775: Perl_sv_force_normal_flags (sv.c:4834) ==26758== by 0x814F6E8: Perl_leave_scope (scope.c:914) ==26758== by 0x814D1FE: Perl_pop_scope (scope.c:110) ==26758== by 0x8158154: Perl_pp_leave (pp_ctl.c:2152) ==26758== by 0x810C4E6: Perl_runops_standard (run.c:41) ==26758== by 0x807D372: S_run_body (perl.c:2400) ==26758== by 0x807CE5A: perl_run (perl.c:2318) ==26758== by 0x805D96C: main (perlmain.c:120) ==26758== ==26758== Use of uninitialised value of size 4 ==26758== at 0x80ED02A: Perl_mg_clear (mg.c:371) ==26758== by 0x8107263: Perl_hv_undef_flags (hv.c:1872) ==26758== by 0x8122975: Perl_sv_clear (sv.c:6294) ==26758== by 0x8123145: Perl_sv_free2 (sv.c:6506) ==26758== by 0x8129A86: Perl_sv_unref_flags (sv.c:9623) ==26758== by 0x811F775: Perl_sv_force_normal_flags (sv.c:4834) ==26758== by 0x814F6E8: Perl_leave_scope (scope.c:914) ==26758== by 0x814D1FE: Perl_pop_scope (scope.c:110) ==26758== by 0x8158154: Perl_pp_leave (pp_ctl.c:2152) ==26758== by 0x810C4E6: Perl_runops_standard (run.c:41) ==26758== by 0x807D372: S_run_body (perl.c:2400) ==26758== by 0x807CE5A: perl_run (perl.c:2318) ==26758== by 0x805D96C: main (perlmain.c:120) ==26758== ==26758== Use of uninitialised value of size 4 ==26758== at 0x80ED033: Perl_mg_clear (mg.c:374) ==26758== by 0x8107263: Perl_hv_undef_flags (hv.c:1872) ==26758== by 0x8122975: Perl_sv_clear (sv.c:6294) ==26758== by 0x8123145: Perl_sv_free2 (sv.c:6506) ==26758== by 0x8129A86: Perl_sv_unref_flags (sv.c:9623) ==26758== by 0x811F775: Perl_sv_force_normal_flags (sv.c:4834) ==26758== by 0x814F6E8: Perl_leave_scope (scope.c:914) ==26758== by 0x814D1FE: Perl_pop_scope (scope.c:110) ==26758== by 0x8158154: Perl_pp_leave (pp_ctl.c:2152) ==26758== by 0x810C4E6: Perl_runops_standard (run.c:41) ==26758== by 0x807D372: S_run_body (perl.c:2400) ==26758== by 0x807CE5A: perl_run (perl.c:2318) ==26758== by 0x805D96C: main (perlmain.c:120) ==26758== ==26758== Invalid read of size 4 ==26758== at 0x80ED041: Perl_mg_clear (mg.c:376) ==26758== by 0x8107263: Perl_hv_undef_flags (hv.c:1872) ==26758== by 0x8122975: Perl_sv_clear (sv.c:6294) ==26758== by 0x8123145: Perl_sv_free2 (sv.c:6506) ==26758== by 0x8129A86: Perl_sv_unref_flags (sv.c:9623) ==26758== by 0x811F775: Perl_sv_force_normal_flags (sv.c:4834) ==26758== by 0x814F6E8: Perl_leave_scope (scope.c:914) ==26758== by 0x814D1FE: Perl_pop_scope (scope.c:110) ==26758== by 0x8158154: Perl_pp_leave (pp_ctl.c:2152) ==26758== by 0x810C4E6: Perl_runops_standard (run.c:41) ==26758== by 0x807D372: S_run_body (perl.c:2400) ==26758== by 0x807CE5A: perl_run (perl.c:2318) ==26758== by 0x805D96C: main (perlmain.c:120) ==26758== Address 0x696c6180 is not stack'd, malloc'd or (recently) free'd ==26758== ==26758== ==26758== Process terminating with default action of signal 11 (SIGSEGV) ==26758== Access not within mapped region at address 0x696C6180 ==26758== at 0x80ED041: Perl_mg_clear (mg.c:376) ==26758== by 0x8107263: Perl_hv_undef_flags (hv.c:1872) ==26758== by 0x8122975: Perl_sv_clear (sv.c:6294) ==26758== by 0x8123145: Perl_sv_free2 (sv.c:6506) ==26758== by 0x8129A86: Perl_sv_unref_flags (sv.c:9623) ==26758== by 0x811F775: Perl_sv_force_normal_flags (sv.c:4834) ==26758== by 0x814F6E8: Perl_leave_scope (scope.c:914) ==26758== by 0x814D1FE: Perl_pop_scope (scope.c:110) ==26758== by 0x8158154: Perl_pp_leave (pp_ctl.c:2152) ==26758== by 0x810C4E6: Perl_runops_standard (run.c:41) ==26758== by 0x807D372: S_run_body (perl.c:2400) ==26758== by 0x807CE5A: perl_run (perl.c:2318) ==26758== by 0x805D96C: main (perlmain.c:120) ==26758== If you believe this happened as a result of a stack ==26758== overflow in your program's main thread (unlikely but ==26758== possible), you can try to increase the size of the ==26758== main thread stack using the --main-stacksize= flag. ==26758== The main thread stack size used in this run was 8388608. (In case you cannot find Glib on CPAN---there's some index issue currently---you can use <http://sourceforge.net/projects/gtk2-perl/files/Glib/1.242/Glib-1.242.tar.gz/download>.) 'git bisect' points at the below commit as the culprit. On 06.03.2012 15:35, Dave Mitchell wrote: > commit 5bec93bead1c10563a402404de095bbdf398790f > Author: David Mitchell<davem [at] iabyn> > AuthorDate: Tue Mar 6 14:26:27 2012 +0000 > Commit: David Mitchell<davem [at] iabyn> > CommitDate: Tue Mar 6 14:26:27 2012 +0000 > > fix slowdown in nested hash freeing
|