Skip Menu |

This queue is for tickets about the Future-AsyncAwait CPAN distribution.

Report information
The Basics
Id: 122673
Status: resolved
Priority: 0/
Queue: Future-AsyncAwait

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

Bug Information
Severity: (no value)
Broken in: 0.07
Fixed in: 0.09



Subject: test failure t/21context-while.t .... perl: pp_hot.c:3380: Perl_leave_adjust_stacks: Assertion `gimme == 2' failed.
$ perl -V Summary of my perl5 (revision 5 version 24 subversion 1) configuration: Platform: osname=linux, osvers=3.16.7-53-desktop, archname=x86_64-linux-thread-multi-ld uname='linux rotechili.localdomain 3.16.7-53-desktop #1 smp preempt fri dec 2 13:19:28 utc 2016 (7b4a1f9) x86_64 x86_64 x86_64 gnulinux ' config_args='-de -Dprefix=/home/daxim/local/share/perlbrew/perls/perl-5.24.1 -DDEBUGGING -Dcf_email=daxim@cpan.org -Dperladmin=daxim@cpan.org -Dusemorebits -Duseshrplib -Dusethreads -Accflags=-fPIC -Aeval:scriptdir=/home/daxim/local/share/perlbrew/perls/perl-5.24.1/bin' hint=recommended, useposix=true, d_sigaction=define useithreads=define, usemultiplicity=define use64bitint=define, use64bitall=define, uselongdouble=define usemymalloc=n, bincompat5005=undef Compiler: cc='cc', ccflags ='-D_REENTRANT -D_GNU_SOURCE -fPIC -fwrapv -DDEBUGGING -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -D_FORTIFY_SOURCE=2', optimize='-O2 -g', cppflags='-D_REENTRANT -D_GNU_SOURCE -fPIC -fwrapv -DDEBUGGING -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include' ccversion='', gccversion='4.8.3 20140627 [gcc-4_8-branch revision 212064]', 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='long double', nvsize=16, Off_t='off_t', lseeksize=8 alignbytes=16, prototype=define Linker and Libraries: ld='cc', ldflags =' -fstack-protector -L/usr/local/lib' libpth=/usr/local/lib /usr/lib64/gcc/x86_64-suse-linux/4.8/include-fixed /usr/lib64/gcc/x86_64-suse-linux/4.8/../../../../x86_64-suse-linux/lib /usr/lib /lib/../lib64 /usr/lib/../lib64 /lib /lib64 /usr/lib64 /usr/local/lib64 libs=-lpthread -lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat perllibs=-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc libc=libc-2.19.so, so=so, useshrplib=true, libperl=libperl.so gnulibc_version='2.19' Dynamic Linking: dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='-Wl,-E -Wl,-rpath,/home/daxim/local/share/perlbrew/perls/perl-5.24.1/lib/5.24.1/x86_64-linux-thread-multi-ld/CORE' cccdlflags='-fPIC', lddlflags='-shared -O2 -g -L/usr/local/lib -fstack-protector' Characteristics of this binary (from libperl): Compile-time options: DEBUGGING HAS_TIMES MULTIPLICITY PERLIO_LAYERS PERL_COPY_ON_WRITE PERL_DONT_CREATE_GVSV PERL_HASH_FUNC_ONE_AT_A_TIME_HARD PERL_IMPLICIT_CONTEXT PERL_MALLOC_WRAP PERL_PRESERVE_IVUV PERL_TRACK_MEMPOOL 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_LONG_DOUBLE USE_PERLIO USE_PERL_ATOF USE_REENTRANT_API Locally applied patches: Devel::PatchPerl 1.30 Built under linux Compiled at Mar 11 2017 19:09:46 %ENV: PERLBREW="command perlbrew" PERLBREW_BASHRC_VERSION="0.78" PERLBREW_HOME="/home/daxim/.perlbrew" PERLBREW_MANPATH="/home/daxim/local/share/perlbrew/perls/perl-5.24.1/man" PERLBREW_PATH="/home/daxim/local/share/perlbrew/bin:/home/daxim/local/share/perlbrew/perls/perl-5.24.1/bin" PERLBREW_PERL="perl-5.24.1" PERLBREW_ROOT="/home/daxim/local/share/perlbrew" PERLBREW_VERSION="0.78" PERL_EXTUTILS_AUTOINSTALL="--default-deps" @INC: /home/daxim/local/share/perlbrew/perls/perl-5.24.1/lib/site_perl/5.24.1/x86_64-linux-thread-multi-ld /home/daxim/local/share/perlbrew/perls/perl-5.24.1/lib/site_perl/5.24.1 /home/daxim/local/share/perlbrew/perls/perl-5.24.1/lib/5.24.1/x86_64-linux-thread-multi-ld /home/daxim/local/share/perlbrew/perls/perl-5.24.1/lib/5.24.1 . $ cpanm --look Future::AsyncAwait --> Working on Future::AsyncAwait Fetching http://www.cpan.org/authors/id/P/PE/PEVANS/Future-AsyncAwait-0.07.tar.gz ... OK Entering /home/daxim/.cpanm/work/1501597898.14171/Future-AsyncAwait-0.07 with /bin/bash ~/.cpanm/work/1501597898.14171/Future-AsyncAwait-0.07$ perl Build.PL Created MYMETA.yml and MYMETA.json Creating new 'Build' script for 'Future-AsyncAwait' version '0.07' ~/.cpanm/work/1501597898.14171/Future-AsyncAwait-0.07$ ./Build test cc -I/home/daxim/local/share/perlbrew/perls/perl-5.24.1/lib/5.24.1/x86_64-linux-thread-multi-ld/CORE -DVERSION="0.07" -DXS_VERSION="0.07" -fPIC -std=c89 -c -D_REENTRANT -D_GNU_SOURCE -fPIC -fwrapv -DDEBUGGING -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -D_FORTIFY_SOURCE=2 -O2 -g -o lib/Future/AsyncAwait.o lib/Future/AsyncAwait.c ExtUtils::Mkbootstrap::Mkbootstrap('blib/arch/auto/Future/AsyncAwait/AsyncAwait.bs') cc -shared -O2 -g -L/usr/local/lib -fstack-protector -o blib/arch/auto/Future/AsyncAwait/AsyncAwait.so lib/Future/AsyncAwait.o t/00use.t .............. ok t/01async-immediate.t .. ok t/02await-immediate.t .. ok t/03await.t ............ ok t/04await-twice.t ...... ok t/05await-expr.t ....... ok t/10pad.t .............. ok t/11contexts.t ......... ok t/20context-block.t .... ok t/21context-while.t .... perl: pp_hot.c:3380: Perl_leave_adjust_stacks: Assertion `gimme == 2' failed. t/21context-while.t .... No subtests run t/90check-await.t ...... ok t/99pod.t .............. ok Test Summary Report ------------------- t/21context-while.t (Wstat: 134 Tests: 0 Failed: 0) Non-zero wait status: 134 Parse errors: No plan found in TAP output Files=12, Tests=59, 1 wallclock secs ( 0.09 usr 0.02 sys + 0.85 cusr 0.11 csys = 1.07 CPU) Result: FAIL Failed 1/12 test programs. 0/59 subtests failed. ~/.cpanm/work/1501597898.14171/Future-AsyncAwait-0.07$ gdb perl GNU gdb (GDB; openSUSE Tumbleweed) 8.0 Copyright (C) 2017 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type "show copying" and "show warranty" for details. This GDB was configured as "x86_64-suse-linux". Type "show configuration" for configuration details. For bug reporting instructions, please see: <http://bugs.opensuse.org/>. Find the GDB manual and other documentation resources online at: <http://www.gnu.org/software/gdb/documentation/>. For help, type "help". Type "apropos word" to search for commands related to "word"... Reading symbols from perl...done. (gdb) r -Mblib t/21context-while.t Starting program: /home/daxim/local/share/perlbrew/perls/perl-5.24.1/bin/perl -Mblib t/21context-while.t warning: the debug information found in "/usr/lib/debug//lib64/ld-2.25.so.debug" does not match "/lib64/ld-linux-x86-64.so.2" (CRC mismatch). Missing separate debuginfo for /lib64/ld-linux-x86-64.so.2 Try: zypper install -C "debuginfo(build-id)=929c44ce252b00c8d5008e7b69e42def654a3d17" warning: the debug information found in "/usr/lib/debug//lib64/libpthread-2.25.so.debug" does not match "/lib64/libpthread.so.0" (CRC mismatch). Missing separate debuginfo for /lib64/libpthread.so.0 Try: zypper install -C "debuginfo(build-id)=37407c4eaf83666c8aa4c8f197d4a5c6aa6b9411" [Thread debugging using libthread_db enabled] Using host libthread_db library "/lib64/libthread_db.so.1". warning: the debug information found in "/usr/lib/debug//lib64/libnsl-2.25.so.debug" does not match "/lib64/libnsl.so.1" (CRC mismatch). Missing separate debuginfo for /lib64/libnsl.so.1 Try: zypper install -C "debuginfo(build-id)=6f2f034f58481b5e377bf6d88f0b800dabdd9ef8" warning: the debug information found in "/usr/lib/debug//lib64/libdl-2.25.so.debug" does not match "/lib64/libdl.so.2" (CRC mismatch). Missing separate debuginfo for /lib64/libdl.so.2 Try: zypper install -C "debuginfo(build-id)=463335f4606617badf4ac8f743a71cc80a74027c" warning: the debug information found in "/usr/lib/debug//lib64/libm-2.25.so.debug" does not match "/lib64/libm.so.6" (CRC mismatch). Missing separate debuginfo for /lib64/libm.so.6 Try: zypper install -C "debuginfo(build-id)=3a47cc1866e6ccb4c417dae67455f5e9f50eb290" warning: the debug information found in "/usr/lib/debug//lib64/libcrypt-2.25.so.debug" does not match "/lib64/libcrypt.so.1" (CRC mismatch). Missing separate debuginfo for /lib64/libcrypt.so.1 Try: zypper install -C "debuginfo(build-id)=7f75c70080bee9a7cca47075684fd18ee991a29c" warning: the debug information found in "/usr/lib/debug//lib64/libutil-2.25.so.debug" does not match "/lib64/libutil.so.1" (CRC mismatch). Missing separate debuginfo for /lib64/libutil.so.1 Try: zypper install -C "debuginfo(build-id)=84471edcdc9fa0188de9769c9c1b36a6bec6f9d7" warning: the debug information found in "/usr/lib/debug//lib64/libc-2.25.so.debug" does not match "/lib64/libc.so.6" (CRC mismatch). Missing separate debuginfo for /lib64/libc.so.6 Try: zypper install -C "debuginfo(build-id)=936986f6f48771374957c090cda015288f0601a1" warning: the debug information found in "/usr/lib/debug//lib64/librt-2.25.so.debug" does not match "/lib/../lib64/librt.so.1" (CRC mismatch). Missing separate debuginfo for /lib/../lib64/librt.so.1 Try: zypper install -C "debuginfo(build-id)=e80154fa481a51b64630feea48a4bc0e5c929093" perl: pp_hot.c:3380: Perl_leave_adjust_stacks: Assertion `gimme == 2' failed. Program received signal SIGABRT, Aborted. 0x00007ffff678da60 in raise () from /lib64/libc.so.6 (gdb) bt full #0 0x00007ffff678da60 in raise () from /lib64/libc.so.6 No symbol table info available. #1 0x00007ffff678f0c6 in abort () from /lib64/libc.so.6 No symbol table info available. #2 0x00007ffff678671a in __assert_fail_base () from /lib64/libc.so.6 No symbol table info available. #3 0x00007ffff6786792 in __assert_fail () from /lib64/libc.so.6 No symbol table info available. #4 0x00007ffff79ce386 in Perl_leave_adjust_stacks (my_perl=my_perl@entry=0x603010, from_sp=0x6088c0, to_sp=0x6088c0, gimme=<optimized out>, pass=1) at pp_hot.c:3380 sp = 0x6088c8 tmps_base = <optimized out> nargs = <optimized out> __PRETTY_FUNCTION__ = "Perl_leave_adjust_stacks" #5 0x00007ffff7a4bb23 in Perl_pp_leaveloop (my_perl=0x603010) at pp_ctl.c:2242 cx = 0x609050 gimme = <optimized out> oldsp = <optimized out> mark = <optimized out> __PRETTY_FUNCTION__ = "Perl_pp_leaveloop" #6 0x00007ffff7993dea in Perl_runops_debug (my_perl=0x603010) at dump.c:2239 No locals. #7 0x00007ffff78fad38 in S_run_body (oldscope=1, my_perl=0x603010) at perl.c:2483 No locals. #8 perl_run (my_perl=0x603010) at perl.c:2406 oldscope = 1 ret = <optimized out> cur_env = {je_prev = 0x603390, je_buf = {{__jmpbuf = {0, 2857308834463963229, 4198295, 140737488344896, 0, 0, -2857309386161825699, -2857291382127896483}, __mask_was_saved = 0, __saved_mask = {__val = {0, 0, 6315208, 4, 6388648, 0, 6303760, 140737349340224, 0, 140737347139304, 0, 140737488344336, 0, 6303760, 6303760, 6416240}}}}, je_ret = 0, je_mustcatch = false, je_old_delaymagic = 0} __PRETTY_FUNCTION__ = "perl_run" #9 0x0000000000400f88 in main (argc=3, argv=0x7fffffffd748, env=0x7fffffffd768) at perlmain.c:116 exitstatus = <optimized out> i = <optimized out>
Perl-level backtrace: (gdb) call Perl_eval_pv("Carp::cluck()", 0) at (eval 7) line 1. eval 'Carp::cluck()' called at t/21context-while.t line 20 eval {...} called at /home/ilmari/.perlbrew/libs/26.0d@std/lib/perl5/Future.pm line 461 main::with_while_body(Future=HASH(0xcd1c88)) called at /home/ilmari/.perlbrew/libs/26.0d@std/lib/perl5/Future.pm line 461 Future::_mark_ready(Future=HASH(0xcd1c88), "done") called at /home/ilmari/.perlbrew/libs/26.0d@std/lib/perl5/Future.pm line 508 Future::done(Future=HASH(0xcd1c88)) called at t/21context-while.t line 29 $1 = (SV *) 0xcdb7a8 C-level backtrace from a perl built with -O0, so variables aren't optimized out: (gdb) bt full #0 __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:51 set = {__val = {0, 140737488343256, 0, 140737327557518, 4222451712, 93825001533264, 93825001533264, 93825001533264, 93825001533264, 93825001533349, 93825001533364, 93825001533264, 93825001533364, 0, 0, 0}} pid = <optimized out> tid = <optimized out> #1 0x00007ffff666b3fa in __GI_abort () at abort.c:89 save_stage = 2 act = {__sigaction_handler = {sa_handler = 0x7fffffffd0b0, sa_sigaction = 0x7fffffffd0b0}, sa_mask = {__val = { 93824994394062, 140737488343296, 4, 0, 0, 140737328548000, 0, 0, 21474836480, 140737488343248, 140737488343448, 140737328576848, 140737328562448, 7935470522486629415, 140737354084352, 140737349265362}}, sa_flags = 3621, sa_restorer = 0x7ffff7b5b070 <__PRETTY_FUNCTION__.16265>} sigs = {__val = {32, 0 <repeats 15 times>}} #2 0x00007ffff6662e37 in __assert_fail_base (fmt=<optimized out>, assertion=assertion@entry=0x7ffff7b5a7d2 "gimme == G_SCALAR", file=file@entry=0x7ffff7b58e6b "pp_hot.c", line=line@entry=3621, function=function@entry=0x7ffff7b5b070 <__PRETTY_FUNCTION__.16265> "Perl_leave_adjust_stacks") at assert.c:92 str = 0x555555e32f50 "" total = 4096 #3 0x00007ffff6662ee2 in __GI___assert_fail (assertion=0x7ffff7b5a7d2 "gimme == G_SCALAR", file=0x7ffff7b58e6b "pp_hot.c", line=3621, function=0x7ffff7b5b070 <__PRETTY_FUNCTION__.16265> "Perl_leave_adjust_stacks") at assert.c:101 No locals. #4 0x00007ffff7942873 in Perl_leave_adjust_stacks (from_sp=0x55555575bb50, to_sp=0x55555575bb50, gimme=166 '\246', pass=1) at pp_hot.c:3621 sp = 0x55555575bb58 tmps_base = 93825001339360 nargs = 0 __PRETTY_FUNCTION__ = "Perl_leave_adjust_stacks" #5 0x00007ffff79fd3cf in Perl_pp_leaveloop () at pp_ctl.c:2294 cx = 0x55555575c2c0 gimme = 166 '\246' base = 0x55555575bb50 oldsp = 0x55555575bb50 __PRETTY_FUNCTION__ = "Perl_pp_leaveloop" #6 0x00007ffff78dbd8b in Perl_runops_debug () at dump.c:2451 No locals. #7 0x00007ffff77cfaef in S_run_body (oldscope=1) at perl.c:2524 Note that 'gimme = 166', which is entirely bogus.
See the attached patch. gimme was missing
Subject: 0001-Fix-RT-122673-loop-gimme-assert.patch
From f6d567a545e0c52ce21aa16f70a828d9d8604216 Mon Sep 17 00:00:00 2001 From: Reini Urban <rurban@cpan.org> Date: Thu, 10 Aug 2017 23:30:43 +0200 Subject: [PATCH] Fix RT #122673 loop gimme assert --- lib/Future/AsyncAwait.xs | 1 + 1 file changed, 1 insertion(+) diff --git lib/Future/AsyncAwait.xs lib/Future/AsyncAwait.xs index 1760b0a..c073e9f 100644 --- lib/Future/AsyncAwait.xs +++ lib/Future/AsyncAwait.xs @@ -227,6 +227,7 @@ static void MY_suspendedstate_suspend(pTHX_ SuspendedState *state, CV *cv) { frame->type = type; frame->loop = cx->blk_loop; + frame->gimme = cx->blk_gimme; if(type == CXt_LOOP_LAZYSV) { /* these two fields are refcounted, so we need to save them from -- 2.8.4 (Apple Git-73)
On Thu Aug 10 17:31:54 2017, RURBAN wrote: Show quoted text
> See the attached patch. > > gimme was missing
Ahyes. Easy enough fix. Thanks. Will be in 0.09 -- Paul Evans
Should be fixed in 0.09 -- Paul Evans