Skip Menu |

To: perlbug [...] perl.org
Date: Mon, 01 Jan 2018 09:40:19 +0100
Subject: Bleadperl v5.27.6-206-g16ada235c3 breaks JGAMBLE/Algorithm-QuineMcCluskey-0.16.tar.gz
From: Andreas Koenig <andreas.koenig.7os6VVqR [...] franz.ak.mind.de>
Download (untitled) / with headers
text/plain 3.6k
bisect ------ commit 16ada235c332e017667585e1a5a00ce43a31c529 Author: Zefram <zefram@fysh.org> Date: Tue Dec 12 09:47:41 2017 +0000 fix GvSV refcounting in sort diagnostics ----------- http://www.cpantesters.org/cpan/report/44ada6c6-e8f1-11e7-a668-697bf7a4fdfd perl -V ------- Summary of my perl5 (revision 5 version 27 subversion 7) configuration: Commit id: da4e040f42421764ef069371d77c008e6b801f45 Platform: osname=linux osvers=4.12.0-2-amd64 archname=x86_64-linux uname='linux k93msid 4.12.0-2-amd64 #1 smp debian 4.12.13-1 (2017-09-19) x86_64 gnulinux ' config_args='-Dprefix=/home/sand/src/perl/repoperls/installed-perls/host/k93msid/v5.27.6-317-gda4e040f42/3c10 -Dmyhostname=k93msid -Dinstallusrbinperl=n -Uversiononly -Dusedevel -des -Ui_db -Dlibswanted=cl pthread socket inet nsl gdbm dbm malloc dl ld sun m crypt sec util c cposix posix ucb BSD gdbm_compat -Uuseithreads -Uuselongdouble -DEBUGGING=none' hint=recommended useposix=true d_sigaction=define useithreads=undef usemultiplicity=undef use64bitint=define use64bitall=define uselongdouble=undef usemymalloc=n default_inc_excludes_dot=define bincompat5005=undef Compiler: cc='cc' ccflags ='-fwrapv -fno-strict-aliasing -pipe -fstack-protector-strong -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -D_FORTIFY_SOURCE=2' optimize='-O2' cppflags='-fwrapv -fno-strict-aliasing -pipe -fstack-protector-strong -I/usr/local/include' ccversion='' gccversion='7.2.0' gccosandvers='' intsize=4 longsize=8 ptrsize=8 doublesize=8 byteorder=12345678 doublekind=3 d_longlong=define longlongsize=8 d_longdbl=define longdblsize=16 longdblkind=3 ivtype='long' ivsize=8 nvtype='double' nvsize=8 Off_t='off_t' lseeksize=8 alignbytes=8 prototype=define Linker and Libraries: ld='cc' ldflags =' -fstack-protector-strong -L/usr/local/lib' libpth=/usr/local/lib /usr/lib/gcc/x86_64-linux-gnu/7/include-fixed /usr/include/x86_64-linux-gnu /usr/lib /lib/x86_64-linux-gnu /lib/../lib /usr/lib/x86_64-linux-gnu /usr/lib/../lib /lib libs=-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc perllibs=-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc libc=libc-2.24.so so=so useshrplib=false libperl=libperl.a gnulibc_version='2.24' Dynamic Linking: dlsrc=dl_dlopen.xs dlext=so d_dlsymun=undef ccdlflags='-Wl,-E' cccdlflags='-fPIC' lddlflags='-shared -O2 -L/usr/local/lib -fstack-protector-strong' Characteristics of this binary (from libperl): Compile-time options: HAS_TIMES PERLIO_LAYERS PERL_COPY_ON_WRITE PERL_DONT_CREATE_GVSV PERL_MALLOC_WRAP PERL_OP_PARENT PERL_PRESERVE_IVUV PERL_USE_DEVEL USE_64_BIT_ALL USE_64_BIT_INT USE_LARGE_FILES USE_LOCALE USE_LOCALE_COLLATE USE_LOCALE_CTYPE USE_LOCALE_NUMERIC USE_LOCALE_TIME USE_PERLIO USE_PERL_ATOF Built under linux Compiled at Dec 17 2017 11:25:33 %ENV: PERL5LIB="" PERL5OPT="" PERL5_CPANPLUS_IS_RUNNING="32655" PERL5_CPAN_IS_RUNNING="32655" PERL_CANARY_STABILITY_NOPROMPT="1" PERL_MM_USE_DEFAULT="1" PERL_USE_UNSAFE_INC="1" @INC: /home/sand/src/perl/repoperls/installed-perls/host/k93msid/v5.27.6-317-gda4e040f42/3c10/lib/site_perl/5.27.7/x86_64-linux /home/sand/src/perl/repoperls/installed-perls/host/k93msid/v5.27.6-317-gda4e040f42/3c10/lib/site_perl/5.27.7 /home/sand/src/perl/repoperls/installed-perls/host/k93msid/v5.27.6-317-gda4e040f42/3c10/lib/5.27.7/x86_64-linux /home/sand/src/perl/repoperls/installed-perls/host/k93msid/v5.27.6-317-gda4e040f42/3c10/lib/5.27.7 . -- andreas
RT-Send-CC: perl5-porters [...] perl.org
Download (untitled) / with headers
text/plain 4.1k
On Mon, 01 Jan 2018 08:40:41 GMT, andreas.koenig.7os6VVqR@franz.ak.mind.de wrote: Show quoted text
> bisect > ------ > commit 16ada235c332e017667585e1a5a00ce43a31c529 > Author: Zefram <zefram@fysh.org> > Date: Tue Dec 12 09:47:41 2017 +0000 > > fix GvSV refcounting in sort > > diagnostics > ----------- > http://www.cpantesters.org/cpan/report/44ada6c6-e8f1-11e7-a668- > 697bf7a4fdfd > > perl -V > ------- > Summary of my perl5 (revision 5 version 27 subversion 7) > configuration: > Commit id: da4e040f42421764ef069371d77c008e6b801f45 > Platform: > osname=linux > osvers=4.12.0-2-amd64 > archname=x86_64-linux > uname='linux k93msid 4.12.0-2-amd64 #1 smp debian 4.12.13-1 (2017- > 09-19) x86_64 gnulinux ' > config_args='-Dprefix=/home/sand/src/perl/repoperls/installed- > perls/host/k93msid/v5.27.6-317-gda4e040f42/3c10 -Dmyhostname=k93msid > -Dinstallusrbinperl=n -Uversiononly -Dusedevel -des -Ui_db > -Dlibswanted=cl pthread socket inet nsl gdbm dbm malloc dl ld sun m > crypt sec util c cposix posix ucb BSD gdbm_compat -Uuseithreads > -Uuselongdouble -DEBUGGING=none' > hint=recommended > useposix=true > d_sigaction=define > useithreads=undef > usemultiplicity=undef > use64bitint=define > use64bitall=define > uselongdouble=undef > usemymalloc=n > default_inc_excludes_dot=define > bincompat5005=undef > Compiler: > cc='cc' > ccflags ='-fwrapv -fno-strict-aliasing -pipe -fstack-protector- > strong -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 > -D_FORTIFY_SOURCE=2' > optimize='-O2' > cppflags='-fwrapv -fno-strict-aliasing -pipe -fstack-protector- > strong -I/usr/local/include' > ccversion='' > gccversion='7.2.0' > gccosandvers='' > intsize=4 > longsize=8 > ptrsize=8 > doublesize=8 > byteorder=12345678 > doublekind=3 > d_longlong=define > longlongsize=8 > d_longdbl=define > longdblsize=16 > longdblkind=3 > ivtype='long' > ivsize=8 > nvtype='double' > nvsize=8 > Off_t='off_t' > lseeksize=8 > alignbytes=8 > prototype=define > Linker and Libraries: > ld='cc' > ldflags =' -fstack-protector-strong -L/usr/local/lib' > libpth=/usr/local/lib /usr/lib/gcc/x86_64-linux-gnu/7/include- > fixed /usr/include/x86_64-linux-gnu /usr/lib /lib/x86_64-linux-gnu > /lib/../lib /usr/lib/x86_64-linux-gnu /usr/lib/../lib /lib > libs=-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc > perllibs=-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc > libc=libc-2.24.so > so=so > useshrplib=false > libperl=libperl.a > gnulibc_version='2.24' > Dynamic Linking: > dlsrc=dl_dlopen.xs > dlext=so > d_dlsymun=undef > ccdlflags='-Wl,-E' > cccdlflags='-fPIC' > lddlflags='-shared -O2 -L/usr/local/lib -fstack-protector-strong' > > > Characteristics of this binary (from libperl): > Compile-time options: > HAS_TIMES > PERLIO_LAYERS > PERL_COPY_ON_WRITE > PERL_DONT_CREATE_GVSV > PERL_MALLOC_WRAP > PERL_OP_PARENT > PERL_PRESERVE_IVUV > PERL_USE_DEVEL > USE_64_BIT_ALL > USE_64_BIT_INT > USE_LARGE_FILES > USE_LOCALE > USE_LOCALE_COLLATE > USE_LOCALE_CTYPE > USE_LOCALE_NUMERIC > USE_LOCALE_TIME > USE_PERLIO > USE_PERL_ATOF > Built under linux > Compiled at Dec 17 2017 11:25:33 > %ENV: > PERL5LIB="" > PERL5OPT="" > PERL5_CPANPLUS_IS_RUNNING="32655" > PERL5_CPAN_IS_RUNNING="32655" > PERL_CANARY_STABILITY_NOPROMPT="1" > PERL_MM_USE_DEFAULT="1" > PERL_USE_UNSAFE_INC="1" > @INC: > /home/sand/src/perl/repoperls/installed-perls/host/k93msid/v5.27.6- > 317-gda4e040f42/3c10/lib/site_perl/5.27.7/x86_64-linux > /home/sand/src/perl/repoperls/installed-perls/host/k93msid/v5.27.6- > 317-gda4e040f42/3c10/lib/site_perl/5.27.7 > /home/sand/src/perl/repoperls/installed-perls/host/k93msid/v5.27.6- > 317-gda4e040f42/3c10/lib/5.27.7/x86_64-linux > /home/sand/src/perl/repoperls/installed-perls/host/k93msid/v5.27.6- > 317-gda4e040f42/3c10/lib/5.27.7 > . >
3 test files are failing, 2 with SEGV and 1 with 'panic: attempt to copy freed scalar'. Please see attached. -- James E Keenan (jkeenan@cpan.org)
Subject: 132671-debugger-output.txt
[Algorithm-QuineMcCluskey-0.16] 578 $ /home/jkeenan/testing/threaded_blead/bin/perl -I/home/jkeenan/testing/threaded_blead/lib -Iblib/lib -d t/13-solvesimple.t Loading DB routines from perl5db.pl version 1.53 Editor support available. Enter h or 'h h' for help, or 'man perldebug' for more help. 1..1 Test2::API::CODE(0x3726710)(/home/jkeenan/testing/threaded_blead/lib/perl5/5.27.8/Test2/API.pm:41): 41: INIT { eval 'END { test2_set_is_end() }; 1' or die $@ } DB<1> n Test2::API::CODE(0x3726710)((eval 217)[/home/jkeenan/testing/threaded_blead/lib/perl5/5.27.8/Test2/API.pm:41]:1): 1: END { test2_set_is_end() }; 1 DB<1> Test::Builder::CODE(0x3aba3a0)(/home/jkeenan/testing/threaded_blead/lib/perl5/5.27.8/Test/Builder.pm:99): 99: Test2::API::test2_load() unless Test2::API::test2_in_preload(); DB<1> main::(t/13-solvesimple.t:11): my($q, $eqn, @expected); DB<1> main::(t/13-solvesimple.t:13): $q = Algorithm::QuineMcCluskey->new( main::(t/13-solvesimple.t:14): title => "Example 3.16 from Introduction to Logic Design, by Sajjan G. Shiva, page 126.", main::(t/13-solvesimple.t:15): width => 4, main::(t/13-solvesimple.t:16): minterms => [ 0, 2, 5 .. 8, 10, 12 .. 15 ], main::(t/13-solvesimple.t:17): ); DB<1> main::(t/13-solvesimple.t:22): @expected = ( main::(t/13-solvesimple.t:23): q/(AD') + (BD) + (B'D') + (CD')/, main::(t/13-solvesimple.t:24): q/(AD') + (BC) + (BD) + (B'D')/, main::(t/13-solvesimple.t:25): q/(AB) + (BC) + (BD) + (B'D')/, main::(t/13-solvesimple.t:26): q/(AB) + (BD) + (B'D') + (CD')/ main::(t/13-solvesimple.t:27): ); DB<1> main::(t/13-solvesimple.t:29): $eqn = $q->solve; DB<1> Signal SEGV at blib/lib/Algorithm/QuineMcCluskey.pm line 759. Algorithm::QuineMcCluskey::recurse_solve(Algorithm::QuineMcCluskey=HASH(0x3d22558), HASH(0x34a13b0), 0) called at blib/lib/Algorithm/QuineMcCluskey.pm line 568 Algorithm::QuineMcCluskey::generate_covers(Algorithm::QuineMcCluskey=HASH(0x3d22558)) called at (eval 208)[/home/jkeenan/testing/threaded_blead/lib/perl5/site_perl/5.27.8/Eval/Closure.pm:149] line 13 Algorithm::QuineMcCluskey::get_covers(Algorithm::QuineMcCluskey=HASH(0x3d22558)) called at blib/lib/Algorithm/QuineMcCluskey.pm line 651 Algorithm::QuineMcCluskey::solve(Algorithm::QuineMcCluskey=HASH(0x3d22558)) called at t/13-solvesimple.t line 29 Aborted (core dumped) [Algorithm-QuineMcCluskey-0.16] 579 $ /home/jkeenan/testing/threaded_blead/bin/perl -I/home/jkeenan/testing/threaded_blead/lib -Iblib/lib -d t/24-solve.t Loading DB routines from perl5db.pl version 1.53 Editor support available. Enter h or 'h h' for help, or 'man perldebug' for more help. 1..3 Test2::API::CODE(0x3579f20)(/home/jkeenan/testing/threaded_blead/lib/perl5/5.27.8/Test2/API.pm:41): 41: INIT { eval 'END { test2_set_is_end() }; 1' or die $@ } DB<1> c Signal SEGV at blib/lib/Algorithm/QuineMcCluskey.pm line 759. Algorithm::QuineMcCluskey::recurse_solve(Algorithm::QuineMcCluskey=HASH(0x3b850b8), HASH(0x32f4650), 0) called at blib/lib/Algorithm/QuineMcCluskey.pm line 568 Algorithm::QuineMcCluskey::generate_covers(Algorithm::QuineMcCluskey=HASH(0x3b850b8)) called at (eval 208)[/home/jkeenan/testing/threaded_blead/lib/perl5/site_perl/5.27.8/Eval/Closure.pm:149] line 13 Algorithm::QuineMcCluskey::get_covers(Algorithm::QuineMcCluskey=HASH(0x3b850b8)) called at blib/lib/Algorithm/QuineMcCluskey.pm line 651 Algorithm::QuineMcCluskey::solve(Algorithm::QuineMcCluskey=HASH(0x3b850b8)) called at t/24-solve.t line 29 Aborted (core dumped) [Algorithm-QuineMcCluskey-0.16] 580 $ /home/jkeenan/testing/threaded_blead/bin/perl -I/home/jkeenan/testing/threaded_blead/lib -Iblib/lib -d t/27-solve.t Loading DB routines from perl5db.pl version 1.53 Editor support available. Enter h or 'h h' for help, or 'man perldebug' for more help. 1..2 Test2::API::CODE(0x3dac070)(/home/jkeenan/testing/threaded_blead/lib/perl5/5.27.8/Test2/API.pm:41): 41: INIT { eval 'END { test2_set_is_end() }; 1' or die $@ } DB<1> c ok 1 - Solutions are more than 2**width in cost panic: attempt to copy freed scalar 43eae08 to 23cb558 at /home/jkeenan/testing/threaded_blead/lib/perl5/5.27.8/perl5db.pl line 4251. at /home/jkeenan/testing/threaded_blead/lib/perl5/5.27.8/perl5db.pl line 4251. Algorithm::QuineMcCluskey::recurse_solve(Algorithm::QuineMcCluskey=HASH(0x43c3870), HASH(0x43ea388), 0) called at blib/lib/Algorithm/QuineMcCluskey.pm line 568 Algorithm::QuineMcCluskey::generate_covers(Algorithm::QuineMcCluskey=HASH(0x43c3870)) called at (eval 208)[/home/jkeenan/testing/threaded_blead/lib/perl5/site_perl/5.27.8/Eval/Closure.pm:149] line 13 Algorithm::QuineMcCluskey::get_covers(Algorithm::QuineMcCluskey=HASH(0x43c3870)) called at blib/lib/Algorithm/QuineMcCluskey.pm line 651 Algorithm::QuineMcCluskey::solve(Algorithm::QuineMcCluskey=HASH(0x43c3870)) called at t/27-solve.t line 49 Attempt to free unreferenced scalar: SV 0x43eae08, Perl interpreter: 0x1dd8010. at t/27-solve.t line 0. # Looks like your test exited with 255 just after 1. Debugged program terminated. Use q to quit or R to restart, use o inhibit_exit to avoid stopping after program termination, h q, h R or h o to get additional info. DB<1> c Use 'q' to quit or 'R' to restart. 'h q' for details. DB<1> q ##### Summary of my perl5 (revision 5 version 27 subversion 8) configuration: Commit id: dce3f5c3fd788f1c2e451e3760f05a347c949eff Platform: osname=linux osvers=4.4.0-104-generic archname=x86_64-linux-thread-multi uname='linux zareason 4.4.0-104-generic #127-ubuntu smp mon dec 11 12:16:42 utc 2017 x86_64 x86_64 x86_64 gnulinux ' config_args='-des -Dusedevel -Dusethreads -Uversiononly -Dprefix=/home/jkeenan/testing/threaded_blead -Dman1dir=none -Dman3dir=none' hint=recommended useposix=true d_sigaction=define useithreads=define usemultiplicity=define use64bitint=define use64bitall=define uselongdouble=undef usemymalloc=n default_inc_excludes_dot=define bincompat5005=undef Compiler: cc='cc' ccflags ='-D_REENTRANT -D_GNU_SOURCE -fwrapv -fno-strict-aliasing -pipe -fstack-protector-strong -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64' optimize='-O2' cppflags='-D_REENTRANT -D_GNU_SOURCE -fwrapv -fno-strict-aliasing -pipe -fstack-protector-strong -I/usr/local/include' ccversion='' gccversion='5.4.1 20160904' gccosandvers='' intsize=4 longsize=8 ptrsize=8 doublesize=8 byteorder=12345678 doublekind=3 d_longlong=define longlongsize=8 d_longdbl=define longdblsize=16 longdblkind=3 ivtype='long' ivsize=8 nvtype='double' nvsize=8 Off_t='off_t' lseeksize=8 alignbytes=8 prototype=define Linker and Libraries: ld='cc' ldflags =' -fstack-protector-strong -L/usr/local/lib' libpth=/usr/local/lib /usr/lib/gcc/x86_64-linux-gnu/5/include-fixed /usr/include/x86_64-linux-gnu /usr/lib /lib/x86_64-linux-gnu /lib/../lib /usr/lib/x86_64-linux-gnu /usr/lib/../lib /lib /lib64 /usr/lib64 libs=-lpthread -lnsl -ldb -ldl -lm -lcrypt -lutil -lc perllibs=-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc libc=libc-2.23.so so=so useshrplib=false libperl=libperl.a gnulibc_version='2.23' Dynamic Linking: dlsrc=dl_dlopen.xs dlext=so d_dlsymun=undef ccdlflags='-Wl,-E' cccdlflags='-fPIC' lddlflags='-shared -O2 -L/usr/local/lib -fstack-protector-strong' Characteristics of this binary (from libperl): Compile-time options: HAS_TIMES MULTIPLICITY PERLIO_LAYERS PERL_COPY_ON_WRITE PERL_DONT_CREATE_GVSV PERL_IMPLICIT_CONTEXT PERL_MALLOC_WRAP PERL_OP_PARENT PERL_PRESERVE_IVUV PERL_USE_DEVEL USE_64_BIT_ALL USE_64_BIT_INT USE_ITHREADS USE_LARGE_FILES USE_LOCALE USE_LOCALE_COLLATE USE_LOCALE_CTYPE USE_LOCALE_NUMERIC USE_LOCALE_TIME USE_PERLIO USE_PERL_ATOF USE_REENTRANT_API
Subject: Re: [perl #132671] Bleadperl v5.27.6-206-g16ada235c3 breaks JGAMBLE/Algorithm-QuineMcCluskey-0.16.tar.gz
From: Zefram <zefram [...] fysh.org>
Date: Mon, 1 Jan 2018 15:24:18 +0000
To: perl5-porters [...] perl.org
Download (untitled) / with headers
text/plain 899b
This problem isn't actually with Algorithm-QuineMcCluskey, but with List-MoreUtils-XS. It's another GvSV refcounting bug in List-MoreUtils-XS that is being uncovered by having fixed pp_sort. We previously saw a similar failure in List-MoreUtils-XS's own test suite, [perl #132578]. A new version of List-MoreUtils-XS has been released which doesn't fail in its own test suite, but still has GvSV refcounting bugs. The one hitting Algorithm-QuineMcCluskey is with pairwise(): $ perl -MDevel::Peek=Dump -MList::MoreUtils::XS=pairwise -lwe 'pairwise { } @{["0"]}, @{["0"]}; Dump $a; Dump $b' SV = UNKNOWN(0xff) (0xfecab0) at 0xfc9128 REFCNT = 0 FLAGS = () SV = UNKNOWN(0xff) (0xfecb88) at 0xfecac8 REFCNT = 0 FLAGS = () This bug falls within the scope of [rt.cpan.org #123868] that I opened in response to [perl #132578]. I'll add a comment to it about this particular problem. -zefram


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

For issues related to this RT instance (aka "perlbug"), please contact perlbug-admin at perl.org