Skip Menu |
 

This queue is for tickets about the NgxQueue CPAN distribution.

Report information
The Basics
Id: 104018
Status: open
Priority: 0/
Queue: NgxQueue

People
Owner: Nobody in particular
Requestors: SREZIC [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: 0.02
Fixed in: (no value)



Subject: Test suite crashes with perl 5.21.4 and newer
MIME-Version: 1.0
X-Mailer: MIME-tools 5.504 (Entity 5.504)
Content-Disposition: inline
X-RT-Interface: Web
Message-ID: <rt-4.0.18-28311-1430165699-499.0-0-0 [...] rt.cpan.org>
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
X-RT-Encrypt: 0
X-RT-Sign: 0
Content-Length: 1206
Download (untitled) / with headers
text/plain 1.1k
The basic.t and sv_leak.t crash with bleadperl on linux and freebsd systems (segmentation fault and bus error or abort). Here's a sample from a Linux system with 5.21.11: Output from '/usr/bin/make test': Running Mkbootstrap for NgxQueue () chmod 644 "NgxQueue.bs" PERL_DL_NONLAZY=1 "/opt/perl-5.21.11t/bin/perl5.21.11" "-MExtUtils::Command::MM" "-MTest::Harness" "-e" "undef *Test::Harness::Switches; test_harness(0, 'inc', 'blib/lib', 'blib/arch'); " t/*.t # Test for: XS # Failed test at t/basic.t line 17. # got: undef # expected: 'foo' # Failed test at t/basic.t line 18. # got: undef # expected: 'foo' t/basic.t .... Failed 2/4 subtests t/pp.t ....... ok t/sv_leak.t .. No subtests run Test Summary Report ------------------- t/basic.t (Wstat: 11 Tests: 4 Failed: 2) Failed tests: 3-4 Non-zero wait status: 11 Parse errors: No plan found in TAP output t/sv_leak.t (Wstat: 6 Tests: 0 Failed: 0) Non-zero wait status: 6 Parse errors: No plan found in TAP output Files=3, Tests=6, 0 wallclock secs ( 0.05 usr 0.02 sys + 0.07 cusr 0.06 csys = 0.20 CPU) Result: FAIL Failed 2/3 test programs. 2/6 subtests failed. make: *** [test_dynamic] Error 255
MIME-Version: 1.0
In-Reply-To: <rt-4.0.18-28311-1430165699-499.0-0-0 [...] rt.cpan.org>
X-Mailer: MIME-tools 5.504 (Entity 5.504)
Content-Disposition: inline
X-RT-Interface: Web
References: <rt-4.0.18-28311-1430165699-499.0-0-0 [...] rt.cpan.org>
Content-Type: text/plain; charset="utf-8"
Message-ID: <rt-4.0.18-26415-1430201480-40.104018-0-0 [...] rt.cpan.org>
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
X-RT-Encrypt: 0
X-RT-Sign: 0
Content-Length: 99
FYI, here is the Xref to the bleadperl RT queue: https://rt.perl.org/Ticket/Display.html?id=124409
MIME-Version: 1.0
In-Reply-To: <rt-4.0.18-28311-1430165699-499.0-0-0 [...] rt.cpan.org>
X-Mailer: MIME-tools 5.504 (Entity 5.504)
X-RT-Interface: Web
References: <rt-4.0.18-28311-1430165699-499.0-0-0 [...] rt.cpan.org>
Content-Type: multipart/mixed; boundary="----------=_1431171856-22019-2"
Message-ID: <rt-4.0.18-22019-1431171856-1838.104018-0-0 [...] rt.cpan.org>
X-RT-Original-Encoding: utf-8
X-RT-Encrypt: 0
X-RT-Sign: 0
Content-Length: 0
Content-Disposition: inline
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
Content-Length: 5290
Download (untitled) / with headers
text/plain 5.1k
On Mon Apr 27 16:14:59 2015, SREZIC wrote: Show quoted text
> The basic.t and sv_leak.t crash with bleadperl on linux and freebsd > systems (segmentation fault and bus error or abort). Here's a sample > from a Linux system with 5.21.11: > > Output from '/usr/bin/make test': > > Running Mkbootstrap for NgxQueue () > chmod 644 "NgxQueue.bs" > PERL_DL_NONLAZY=1 "/opt/perl-5.21.11t/bin/perl5.21.11" "- > MExtUtils::Command::MM" "-MTest::Harness" "-e" "undef > *Test::Harness::Switches; test_harness(0, 'inc', 'blib/lib', > 'blib/arch'); " t/*.t > # Test for: XS > > # Failed test at t/basic.t line 17. > # got: undef > # expected: 'foo' > > # Failed test at t/basic.t line 18. > # got: undef > # expected: 'foo' > t/basic.t .... > Failed 2/4 subtests > t/pp.t ....... ok > t/sv_leak.t .. > No subtests run > > Test Summary Report > ------------------- > t/basic.t (Wstat: 11 Tests: 4 Failed: 2) > Failed tests: 3-4 > Non-zero wait status: 11 > Parse errors: No plan found in TAP output > t/sv_leak.t (Wstat: 6 Tests: 0 Failed: 0) > Non-zero wait status: 6 > Parse errors: No plan found in TAP output > Files=3, Tests=6, 0 wallclock secs ( 0.05 usr 0.02 sys + 0.07 cusr > 0.06 csys = 0.20 CPU) > Result: FAIL > Failed 2/3 test programs. 2/6 subtests failed. > make: *** [test_dynamic] Error 255
Still present in perl-5.22.0 RC0: ##### cpan[2]> test NgxQueue Running test for module 'NgxQueue' Fetching with LWP: http://www.cpan.org/authors/id/T/TY/TYPESTER/NgxQueue-0.02.tar.gz Fetching with LWP: http://www.cpan.org/authors/id/T/TY/TYPESTER/CHECKSUMS Checksum for /home/jkeenan/.cpan/sources/authors/id/T/TY/TYPESTER/NgxQueue-0.02.tar.gz ok Configuring T/TY/TYPESTER/NgxQueue-0.02.tar.gz with Makefile.PL Cannot determine perl version info from lib/NgxQueue.pm Writing ppport.h Checking if your kit is complete... Looks good Generating a Unix-style Makefile Writing Makefile for NgxQueue Writing MYMETA.yml and MYMETA.json Merging cpanfile prereqs to MYMETA.yml Merging cpanfile prereqs to MYMETA.json TYPESTER/NgxQueue-0.02.tar.gz /home/jkeenan/testing/blead/bin/perl Makefile.PL INSTALLDIRS=site -- OK Running make for T/TY/TYPESTER/NgxQueue-0.02.tar.gz cp lib/NgxQueue.pm blib/lib/NgxQueue.pm cp lib/NgxQueue/PP.pm blib/lib/NgxQueue/PP.pm Running Mkbootstrap for NgxQueue () chmod 644 "NgxQueue.bs" "/home/jkeenan/testing/blead/bin/perl" "-Iinc" "/home/jkeenan/testing/blead/lib/perl5/5.22.0/ExtUtils/xsubpp" -typemap "/home/jkeenan/testing/blead/lib/perl5/5.22.0/ExtUtils/typemap" src/queue.xs > src/queue.xsc && mv src/queue.xsc src/queue.c cc -c "-I." "-I." -fwrapv -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -Wall -W -Wno-comment -O2 -DVERSION=\"0.02\" -DXS_VERSION=\"0.02\" -o src/queue.o -fPIC "-I/home/jkeenan/testing/blead/lib/perl5/5.22.0/x86_64-linux/CORE" -DUSE_PPPORT src/queue.c In file included from /home/jkeenan/testing/blead/lib/perl5/5.22.0/x86_64-linux/CORE/perl.h:3738:0, from src/queue.xs:2: src/queue.xs: In function ‘XS_NgxQueue_foreach’: /home/jkeenan/testing/blead/lib/perl5/5.22.0/x86_64-linux/CORE/cop.h:1186:10: warning: variable ‘newsp’ set but not used [-Wunused-but-set-variable] SV **newsp; /* set by POPBLOCK */ \ ^ src/queue.xs:183:5: note: in expansion of macro ‘dMULTICALL’ dMULTICALL; ^ rm -f blib/arch/auto/NgxQueue/NgxQueue.so cc -shared -O2 -L/usr/local/lib -fstack-protector src/queue.o -o blib/arch/auto/NgxQueue/NgxQueue.so \ \ chmod 755 blib/arch/auto/NgxQueue/NgxQueue.so "/home/jkeenan/testing/blead/bin/perl" "-Iinc" -MExtUtils::Command::MM -e 'cp_nonempty' -- NgxQueue.bs blib/arch/auto/NgxQueue/NgxQueue.bs 644 Manifying 2 pod documents TYPESTER/NgxQueue-0.02.tar.gz /usr/bin/make -- OK Running make test Running Mkbootstrap for NgxQueue () chmod 644 "NgxQueue.bs" PERL_DL_NONLAZY=1 "/home/jkeenan/testing/blead/bin/perl" "-MExtUtils::Command::MM" "-MTest::Harness" "-e" "undef *Test::Harness::Switches; test_harness(0, 'inc', 'blib/lib', 'blib/arch'); " t/*.t t/basic.t .... # Test for: XS t/basic.t .... 1/? # Failed test at t/basic.t line 17. # got: undef # expected: 'foo' # Failed test at t/basic.t line 18. # got: undef # expected: 'foo' t/basic.t .... Failed 2/4 subtests t/pp.t ....... ok t/sv_leak.t .. *** Error in `/home/jkeenan/testing/blead/bin/perl': malloc(): memory corruption (fast): 0x000000000279c780 *** t/sv_leak.t .. No subtests run Test Summary Report ------------------- t/basic.t (Wstat: 139 Tests: 4 Failed: 2) Failed tests: 3-4 Non-zero wait status: 139 Parse errors: No plan found in TAP output t/sv_leak.t (Wstat: 134 Tests: 0 Failed: 0) Non-zero wait status: 134 Parse errors: No plan found in TAP output Files=3, Tests=6, 0 wallclock secs ( 0.02 usr 0.00 sys + 0.04 cusr 0.00 csys = 0.06 CPU) Result: FAIL Failed 2/3 test programs. 2/6 subtests failed. make: *** [test_dynamic] Error 255 TYPESTER/NgxQueue-0.02.tar.gz /usr/bin/make test -- NOT OK //hint// to see the cpan-testers results for installing this module, try: reports TYPESTER/NgxQueue-0.02.tar.gz Failed during this command: TYPESTER/NgxQueue-0.02.tar.gz : make_test NO #####
MIME-Version: 1.0
Subject: perl-5.22.0-RC0.V.txt
X-Mailer: MIME-tools 5.504 (Entity 5.504)
Content-Type: text/plain; charset="utf-8"; name="perl-5.22.0-RC0.V.txt"
Content-Disposition: inline; filename="perl-5.22.0-RC0.V.txt"
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
Content-Length: 3477
Summary of my perl5 (revision 5 version 22 subversion 0) configuration: Commit id: 416c06fc852c00a948ade2fd39e7bf1b9f00ca9d Platform: osname=linux, osvers=3.13.0-52-generic, archname=x86_64-linux uname='linux zareason 3.13.0-52-generic #86-ubuntu smp mon may 4 04:32:59 utc 2015 x86_64 x86_64 x86_64 gnulinux ' config_args='-des -Dusedevel -Uversiononly -Dprefix=/home/jkeenan/testing/blead -Dman1dir=none -Dman3dir=none' hint=recommended, useposix=true, d_sigaction=define useithreads=undef, usemultiplicity=undef use64bitint=define, use64bitall=define, uselongdouble=undef usemymalloc=n, bincompat5005=undef Compiler: cc='cc', ccflags ='-fwrapv -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64', optimize='-O2', cppflags='-fwrapv -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include' ccversion='', gccversion='4.8.2', 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 -L/usr/local/lib' libpth=/usr/local/lib /usr/lib/gcc/x86_64-linux-gnu/4.8/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.19.so, so=so, useshrplib=false, libperl=libperl.a gnulibc_version='2.19' 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' Characteristics of this binary (from libperl): Compile-time options: HAS_TIMES PERLIO_LAYERS PERL_DONT_CREATE_GVSV PERL_HASH_FUNC_ONE_AT_A_TIME_HARD PERL_MALLOC_WRAP PERL_NEW_COPY_ON_WRITE 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 Locally applied patches: RC0 Built under linux Compiled at May 9 2015 07:27:49 %ENV: PERL5LIB="/home/jkeenan/perl5/lib/perl5" PERLBREW_BASHRC_VERSION="0.67" PERLBREW_HOME="/home/jkeenan/.perlbrew" PERLBREW_MANPATH="/home/jkeenan/perl5/perlbrew/perls/perl-5.20.1/man" PERLBREW_PATH="/home/jkeenan/perl5/perlbrew/bin:/home/jkeenan/perl5/perlbrew/perls/perl-5.20.1/bin" PERLBREW_PERL="perl-5.20.1" PERLBREW_ROOT="/home/jkeenan/perl5/perlbrew" PERLBREW_VERSION="0.67" PERL_LOCAL_LIB_ROOT="/home/jkeenan/perl5" PERL_MB_OPT="--install_base "/home/jkeenan/perl5"" PERL_MM_OPT="INSTALL_BASE=/home/jkeenan/perl5" PERL_WORKDIR="gitwork/perl" @INC: /home/jkeenan/perl5/lib/perl5/x86_64-linux /home/jkeenan/perl5/lib/perl5 /home/jkeenan/testing/blead/lib/perl5/site_perl/5.22.0/x86_64-linux /home/jkeenan/testing/blead/lib/perl5/site_perl/5.22.0 /home/jkeenan/testing/blead/lib/perl5/5.22.0/x86_64-linux /home/jkeenan/testing/blead/lib/perl5/5.22.0 .
MIME-Version: 1.0
In-Reply-To: <rt-4.0.18-28311-1430165699-499.0-0-0 [...] rt.cpan.org>
X-Mailer: MIME-tools 5.504 (Entity 5.504)
X-RT-Interface: Web
References: <rt-4.0.18-28311-1430165699-499.0-0-0 [...] rt.cpan.org>
Content-Type: multipart/mixed; boundary="----------=_1431407822-30870-3"
Message-ID: <rt-4.0.18-30870-1431407822-1069.104018-0-0 [...] rt.cpan.org>
X-RT-Original-Encoding: utf-8
X-RT-Encrypt: 0
X-RT-Sign: 0
Content-Length: 0
Content-Disposition: inline
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
Content-Length: 455
Download (untitled) / with headers
text/plain 455b
On Mon Apr 27 16:14:59 2015, SREZIC wrote: Show quoted text
> The basic.t and sv_leak.t crash with bleadperl on linux and freebsd > systems (segmentation fault and bus error or abort). Here's a sample > from a Linux system with 5.21.11:
queue.xs uses the PERL_UNUSED_ARG() macro on expressions with side-effects: eg. PERL_UNUSED_VAR(SvREFCNT_inc(queue->data)); Unwrapping those expressions allows NgxQueue to pass on blead. The attached patch does just that. Tony
MIME-Version: 1.0
Subject: ngxqueue.diff
X-Mailer: MIME-tools 5.504 (Entity 5.504)
Content-Type: text/x-diff; name="ngxqueue.diff"
Content-Disposition: inline; filename="ngxqueue.diff"
Content-Transfer-Encoding: binary
Content-Length: 2776
Download ngxqueue.diff
text/x-diff 2.7k
Only in NgxQueue-0.02-IPKpQ1/: blib Only in NgxQueue-0.02-IPKpQ1/: Makefile diff -ru -x '*~' NgxQueue-0.02-UUfuCY/Makefile.old NgxQueue-0.02-IPKpQ1/Makefile.old --- NgxQueue-0.02-UUfuCY/Makefile.old 2015-05-12 14:55:14.000000000 +1000 +++ NgxQueue-0.02-IPKpQ1/Makefile.old 2015-05-12 14:56:03.000000000 +1000 @@ -583,10 +583,10 @@ # Delete temporary files (via clean) and also delete dist files realclean purge :: clean realclean_subdirs - $(RM_F) \ - $(OBJECT) $(MAKEFILE_OLD) \ + $(MAKEFILE_OLD) $(OBJECT) \ $(FIRST_MAKEFILE) - $(RM_RF) \ - MYMETA.yml $(DISTVNAME) + $(DISTVNAME) MYMETA.yml # --- MakeMaker metafile section: Only in NgxQueue-0.02-IPKpQ1/: MYMETA.json Only in NgxQueue-0.02-IPKpQ1/: MYMETA.yml Only in NgxQueue-0.02-IPKpQ1/: pm_to_blib Only in NgxQueue-0.02-IPKpQ1/: ppport.h Only in NgxQueue-0.02-IPKpQ1/src: queue.c Only in NgxQueue-0.02-IPKpQ1/src: queue.o diff -ru -x '*~' NgxQueue-0.02-UUfuCY/src/queue.xs NgxQueue-0.02-IPKpQ1/src/queue.xs --- NgxQueue-0.02-UUfuCY/src/queue.xs 2013-03-13 16:59:00.000000000 +1100 +++ NgxQueue-0.02-IPKpQ1/src/queue.xs 2015-05-12 15:09:46.000000000 +1000 @@ -86,7 +86,7 @@ { PERL_UNUSED_VAR(ix); ngx_queue_insert_head(&h->queue, &x->queue); - PERL_UNUSED_VAR(SvREFCNT_inc(x->data)); + SvREFCNT_inc_void(x->data); } void @@ -94,7 +94,7 @@ CODE: { ngx_queue_insert_tail(&h->queue, &x->queue); - PERL_UNUSED_VAR(SvREFCNT_inc(x->data)); + SvREFCNT_inc_void(x->data); } NgxQueue @@ -103,7 +103,7 @@ { ngx_queue_t* q = ngx_queue_head(&h->queue); RETVAL = ngx_queue_data(q, p5_ngx_queue_t, queue); - PERL_UNUSED_VAR(SvREFCNT_inc(RETVAL->data)); + SvREFCNT_inc_void(RETVAL->data); } OUTPUT: RETVAL @@ -114,7 +114,7 @@ { ngx_queue_t* q = ngx_queue_last(&h->queue); RETVAL = ngx_queue_data(q, p5_ngx_queue_t, queue); - PERL_UNUSED_VAR(SvREFCNT_inc(RETVAL->data)); + SvREFCNT_inc_void(RETVAL->data); } OUTPUT: RETVAL @@ -125,7 +125,7 @@ { ngx_queue_t* q = ngx_queue_next(&h->queue); RETVAL = ngx_queue_data(q, p5_ngx_queue_t, queue); - PERL_UNUSED_VAR(SvREFCNT_inc(RETVAL->data)); + SvREFCNT_inc_void(RETVAL->data); } OUTPUT: RETVAL @@ -136,7 +136,7 @@ { ngx_queue_t* q = ngx_queue_prev(&h->queue); RETVAL = ngx_queue_data(q, p5_ngx_queue_t, queue); - PERL_UNUSED_VAR(SvREFCNT_inc(RETVAL->data)); + SvREFCNT_inc_void(RETVAL->data); } OUTPUT: RETVAL @@ -188,7 +188,7 @@ NgxQueue queue = ngx_queue_data(q, p5_ngx_queue_t, queue); sv_setref_pv(GvSV(PL_defgv), "NgxQueue", (void*)queue); if (queue->data) { - PERL_UNUSED_VAR(SvREFCNT_inc(queue->data)); + SvREFCNT_inc_void(queue->data); } MULTICALL; }


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

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.