msgpack-perl
msgpack-perl copied to clipboard
failed test with perl5.19.1?
does anyone reproduce it?
cp lib/Data/MessagePack/Boolean.pm blib/lib/Data/MessagePack/Boolean.pm
cp lib/Data/MessagePack/Unpacker.pod blib/lib/Data/MessagePack/Unpacker.pod
cp lib/Data/MessagePack/PP.pm blib/lib/Data/MessagePack/PP.pm
cp lib/Data/MessagePack.pm blib/lib/Data/MessagePack.pm
/Users/yoshimin/perl5/perlbrew/perls/perl-5.19.1/bin/perl5.19.1 "-Iinc" /Users/yoshimin/perl5/perlbrew/perls/perl-5.19.1/lib/5.19.1/ExtUtils/xsubpp -typemap /Users/yoshimin
/perl5/perlbrew/perls/perl-5.19.1/lib/5.19.1/ExtUtils/typemap xs-src/MessagePack.xs > xs-src/MessagePack.xsc && mv xs-src/MessagePack.xsc xs-src/MessagePack.c
Please specify prototyping behavior for MessagePack.xs (see perlxs manual)
cc -c "-I." "-Iinclude" "-I." -fno-common -DPERL_DARWIN -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include -Wall -W -Wno-comment -O3 -DVERSION=\"0.47\" -DX
S_VERSION=\"0.47\" -o xs-src/MessagePack.o "-I/Users/yoshimin/perl5/perlbrew/perls/perl-5.19.1/lib/5.19.1/darwin-2level/CORE" -DUSE_PPPORT xs-src/MessagePack.c
xs-src/MessagePack.c:206:17: warning: unused variable 'file' [-Wunused-variable]
const char* file = __FILE__;
^
1 warning generated.
cc -c "-I." "-Iinclude" "-I." -fno-common -DPERL_DARWIN -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include -Wall -W -Wno-comment -O3 -DVERSION=\"0.47\" -DX
S_VERSION=\"0.47\" -o xs-src/pack.o "-I/Users/yoshimin/perl5/perlbrew/perls/perl-5.19.1/lib/5.19.1/darwin-2level/CORE" -DUSE_PPPORT xs-src/pack.c
cc -c "-I." "-Iinclude" "-I." -fno-common -DPERL_DARWIN -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include -Wall -W -Wno-comment -O3 -DVERSION=\"0.47\" -DX
S_VERSION=\"0.47\" -o xs-src/unpack.o "-I/Users/yoshimin/perl5/perlbrew/perls/perl-5.19.1/lib/5.19.1/darwin-2level/CORE" -DUSE_PPPORT xs-src/unpack.c
Running Mkbootstrap for Data::MessagePack ()
chmod 644 MessagePack.bs
rm -f blib/arch/auto/Data/MessagePack/MessagePack.bundle
env MACOSX_DEPLOYMENT_TARGET=10.3 cc -bundle -undefined dynamic_lookup -L/usr/local/lib -fstack-protector xs-src/MessagePack.o xs-src/pack.o xs-src/unpack.o -o blib/arch/a
uto/Data/MessagePack/MessagePack.bundle \
\
chmod 755 blib/arch/auto/Data/MessagePack/MessagePack.bundle
cp MessagePack.bs blib/arch/auto/Data/MessagePack/MessagePack.bs
chmod 644 blib/arch/auto/Data/MessagePack/MessagePack.bs
PERL_DL_NONLAZY=1 /Users/yoshimin/perl5/perlbrew/perls/perl-5.19.1/bin/perl5.19.1 "-MExtUtils::Command::MM" "-e" "test_harness(0, 'inc', 'blib/lib', 'blib/arch')" t/*.t xt/*
.t xt/leaks/*.t
t/00_compile.t .............. 1/1 # Testing Data::MessagePack/0.47 (XS)
# byteoder: 12345678, ivsize=8
t/00_compile.t .............. ok
t/01_pack.t ................. 1/43
# Failed test 'dump a1 33'
# at t/01_pack.t line 13.
# got: 'cb 40 08 00 00 00 00 00 00'
# expected: 'a1 33'
# Looks like you failed 1 test of 43.
t/01_pack.t ................. Dubious, test returned 1 (wstat 256, 0x100)
Failed 1/43 subtests
t/02_unpack.t ............... ok
t/03_stream_unpack.t ........ ok
t/04_invert.t ............... ok
t/05_preferred_int.t ........ ok
t/06_stream_unpack2.t ....... ok
t/07_break.t ................ ok
t/08_cycle.t ................ ok
t/09_stddata.t .............. ok
t/10_splitted_bytes.t ....... ok
t/11_stream_unpack3.t ....... ok
t/12_stream_unpack4.t ....... ok
t/13_booleans.t ............. ok
t/14_invalid_data.t ......... ok
t/15_utf8.t ................. ok
t/16_unpacker_for_larges.t .. ok
t/17_canonical.t ............ ok
t/18_new_interface.t ........ ok
t/19_utf8_property.t ........ ok
t/20_de.t ................... ok
t/21_dirty_float.t .......... ok
t/22_pid_pack_unpack.t ...... ok
t/23-empty-key.t ............ ok
t/24_tied.t ................. ok
t/40_threads.t .............. skipped: no threads
t/50_leaktrace.t ............ skipped: Test requires module 'Test::LeakTrace' but it's not found
xt/99_pod.t ................. skipped: Test::Pod 1.00 required for testing POD
xt/leaks/normal.t ........... skipped: $ENV{LEAK_TEST} is required
xt/leaks/stream.t ........... skipped: $ENV{LEAK_TEST} is required
perl -V
Summary of my perl5 (revision 5 version 19 subversion 1) configuration:
Platform:
osname=darwin, osvers=12.4.0, archname=darwin-2level
uname='darwin xxxx.local 12.4.0 darwin kernel version 12.4.0: wed may 1 17:57:12 pdt 2013; root:xnu-2050.24.15~1release_x86_64 x86_64 '
config_args='-de -Dprefix=/Users/yoshimin/perl5/perlbrew/perls/perl-5.19.1 -Dusedevel -Aeval:scriptdir=/Users/yoshimin/perl5/perlbrew/perls/perl-5.19.1/bin'
hint=recommended, useposix=true, d_sigaction=define
useithreads=undef, usemultiplicity=undef
useperlio=define, d_sfio=undef, uselargefiles=define, usesocks=undef
use64bitint=define, use64bitall=define, uselongdouble=undef
usemymalloc=n, bincompat5005=undef
Compiler:
cc='cc', ccflags ='-fno-common -DPERL_DARWIN -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include',
optimize='-O3',
cppflags='-fno-common -DPERL_DARWIN -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include'
ccversion='', gccversion='4.2.1 Compatible Apple LLVM 4.2 (clang-425.0.28)', gccosandvers=''
intsize=4, longsize=8, ptrsize=8, doublesize=8, byteorder=12345678
d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=16
ivtype='long', ivsize=8, nvtype='double', nvsize=8, Off_t='off_t', lseeksize=8
alignbytes=8, prototype=define
Linker and Libraries:
ld='env MACOSX_DEPLOYMENT_TARGET=10.3 cc', ldflags =' -fstack-protector -L/usr/local/lib'
libpth=/usr/local/lib /usr/lib
libs=-lgdbm -ldbm -ldl -lm -lutil -lc
perllibs=-ldl -lm -lutil -lc
libc=, so=dylib, useshrplib=false, libperl=libperl.a
gnulibc_version=''
Dynamic Linking:
dlsrc=dl_dlopen.xs, dlext=bundle, d_dlsymun=undef, ccdlflags=' '
cccdlflags=' ', lddlflags=' -bundle -undefined dynamic_lookup -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_PERLIO
USE_PERL_ATOF
Built under darwin
Compiled at Jun 22 2013 21:03:29
%ENV:
PERLBREW_BASHRC_VERSION="0.64"
PERLBREW_HOME="/Users/yoshimin/.perlbrew"
PERLBREW_MANPATH="/Users/yoshimin/perl5/perlbrew/perls/perl-5.19.1/man"
PERLBREW_PATH="/Users/yoshimin/perl5/perlbrew/bin:/Users/yoshimin/perl5/perlbrew/perls/perl-5.19.1/bin"
PERLBREW_PERL="perl-5.19.1"
PERLBREW_ROOT="/Users/yoshimin/perl5/perlbrew"
PERLBREW_VERSION="0.64"
@INC:
/Users/yoshimin/perl5/perlbrew/perls/perl-5.19.1/lib/site_perl/5.19.1/darwin-2level
/Users/yoshimin/perl5/perlbrew/perls/perl-5.19.1/lib/site_perl/5.19.1
/Users/yoshimin/perl5/perlbrew/perls/perl-5.19.1/lib/5.19.1/darwin-2level
/Users/yoshimin/perl5/perlbrew/perls/perl-5.19.1/lib/5.19.1
I also tried to build with perl5.18.0. It does not cause failing test.
NOTE
#!perl
use strict;
use warnings;
use Devel::Peek;
my $a = do { my $x = 3.0; my $y = "$x"; $x };
Dump($a);
Output of Perl-5.19.1 is different from others(e.g. PV=0)
perl-5.8.9
==========
SV = PVNV(0x9c80400) at 0x9c7c6b8
REFCNT = 1
FLAGS = (PADBUSY,PADMY,NOK,POK,pNOK,pPOK)
IV = 0
NV = 3
PV = 0x9ca06a8 "3"\0
CUR = 1
LEN = 4
perl-5.16.1
==========
SV = PVNV(0x822d6a4) at 0x8243948
REFCNT = 1
FLAGS = (PADMY,NOK,POK,pNOK,pPOK)
IV = 0
NV = 3
PV = 0x8246578 "3"\0
CUR = 1
LEN = 12
perl-5.18.0
==========
SV = PVNV(0x8f8b738) at 0x8fa28c8
REFCNT = 1
FLAGS = (PADMY,NOK,POK,pNOK,pPOK)
IV = 0
NV = 3
PV = 0x8fd7858 "3"\0
CUR = 1
LEN = 12
perl-5.19.1
==========
SV = PVNV(0x98f9738) at 0x9910978
REFCNT = 1
FLAGS = (PADMY,NOK,pNOK)
IV = 0
NV = 3
PV = 0
I have two questions.
- Is it a bug?
- Could you try this case with 5.19.0?
tokuhirom
On Sun, Jun 30, 2013 at 6:04 PM, Syohei YOSHIDA [email protected]:
#!perluse strict;use warnings;use Devel::Peek; my $a = do { my $x = 3.0; my $y = "$x"; $x };Dump($a);
Output of Perl-5.19.1 is different from others(e.g. PV=0)
perl-5.8.9
SV = PVNV(0x9c80400) at 0x9c7c6b8 REFCNT = 1 FLAGS = (PADBUSY,PADMY,NOK,POK,pNOK,pPOK) IV = 0 NV = 3 PV = 0x9ca06a8 "3"\0 CUR = 1 LEN = 4
perl-5.16.1
SV = PVNV(0x822d6a4) at 0x8243948 REFCNT = 1 FLAGS = (PADMY,NOK,POK,pNOK,pPOK) IV = 0 NV = 3 PV = 0x8246578 "3"\0 CUR = 1 LEN = 12
perl-5.18.0
SV = PVNV(0x8f8b738) at 0x8fa28c8 REFCNT = 1 FLAGS = (PADMY,NOK,POK,pNOK,pPOK) IV = 0 NV = 3 PV = 0x8fd7858 "3"\0 CUR = 1 LEN = 12
perl-5.19.1
SV = PVNV(0x98f9738) at 0x9910978 REFCNT = 1 FLAGS = (PADMY,NOK,pNOK) IV = 0 NV = 3 PV = 0
— Reply to this email directly or view it on GitHubhttps://github.com/msgpack/msgpack-perl/issues/14#issuecomment-20244330 .
Tests are successed with Perl 5.19.0
% perl -V
Summary of my perl5 (revision 5 version 19 subversion 0) configuration:
Platform:
osname=darwin, osvers=12.4.0, archname=darwin-thread-multi-2level
uname='darwin ibanez.local 12.4.0 darwin kernel version 12.4.0: wed may 1 17:57:12 pdt 2013; root:xnu-2050.24.15~1release_x86_64 x86_64 '
config_args='-de -Duserelocatableinc -Dprefix=/Users/syohei/perl5/perlbrew/perls/perl-5.19.0 -Dusethreads -Dusedevel -Aeval:scriptdir=/Users/syohei/perl5/perlbrew/perls/perl-5.19.0/bin'
hint=recommended, useposix=true, d_sigaction=define
useithreads=define, usemultiplicity=define
useperlio=define, d_sfio=undef, uselargefiles=define, usesocks=undef
use64bitint=define, use64bitall=define, uselongdouble=undef
usemymalloc=n, bincompat5005=undef
Compiler:
cc='cc', ccflags ='-fno-common -DPERL_DARWIN -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include',
optimize='-O3',
cppflags='-fno-common -DPERL_DARWIN -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include'
ccversion='', gccversion='4.2.1 Compatible Apple Clang 4.0 ((tags/Apple/clang-421.0.60))', gccosandvers=''
intsize=4, longsize=8, ptrsize=8, doublesize=8, byteorder=12345678
d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=16
ivtype='long', ivsize=8, nvtype='double', nvsize=8, Off_t='off_t', lseeksize=8
alignbytes=8, prototype=define
Linker and Libraries:
ld='env MACOSX_DEPLOYMENT_TARGET=10.3 cc', ldflags =' -fstack-protector -L/usr/local/lib'
libpth=/usr/local/lib /usr/lib
libs=-lgdbm -ldbm -ldl -lm -lutil -lc
perllibs=-ldl -lm -lutil -lc
libc=, so=dylib, useshrplib=false, libperl=libperl.a
gnulibc_version=''
Dynamic Linking:
dlsrc=dl_dlopen.xs, dlext=bundle, d_dlsymun=undef, ccdlflags=' '
cccdlflags=' ', lddlflags=' -bundle -undefined dynamic_lookup -L/usr/local/lib -fstack-protector'
Characteristics of this binary (from libperl):
Compile-time options: HAS_TIMES MULTIPLICITY PERLIO_LAYERS
PERL_DONT_CREATE_GVSV
PERL_HASH_FUNC_ONE_AT_A_TIME_HARD
PERL_IMPLICIT_CONTEXT PERL_MALLOC_WRAP
PERL_PRESERVE_IVUV PERL_SAWAMPERSAND 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_PERLIO
USE_PERL_ATOF USE_REENTRANT_API
Built under darwin
Compiled at Jun 30 2013 19:53:50
%ENV:
PERLBREW_BASHRC_VERSION="0.50"
PERLBREW_HOME="/Users/syohei/.perlbrew"
PERLBREW_MANPATH="/Users/syohei/perl5/perlbrew/perls/perl-5.19.0/man"
PERLBREW_PATH="/Users/syohei/perl5/perlbrew/bin:/Users/syohei/perl5/perlbrew/perls/perl-5.19.0/bin"
PERLBREW_PERL="perl-5.19.0"
PERLBREW_ROOT="/Users/syohei/perl5/perlbrew"
PERLBREW_VERSION="0.50"
PERLDOC_PAGER="less -R"
@INC:
/Users/syohei/perl5/perlbrew/perls/perl-5.19.0/lib/site_perl/5.19.0/darwin-thread-multi-2level
/Users/syohei/perl5/perlbrew/perls/perl-5.19.0/lib/site_perl/5.19.0
/Users/syohei/perl5/perlbrew/perls/perl-5.19.0/lib/5.19.0/darwin-thread-multi-2level
/Users/syohei/perl5/perlbrew/perls/perl-5.19.0/lib/5.19.0
.
% make test
PERL_DL_NONLAZY=1 /Users/syohei/perl5/perlbrew/perls/perl-5.19.0/bin/perl5.19.0 "-MExtUtils::Command::MM" "-e" "test_harness(0, 'inc', 'blib/lib', 'blib/arch')" t/*.t
t/00_compile.t .............. 1/1 # Testing Data::MessagePack/0.47 (XS)
# byteoder: 12345678, ivsize=8
t/00_compile.t .............. ok
t/01_pack.t ................. ok
t/02_unpack.t ............... ok
t/03_stream_unpack.t ........ ok
t/04_invert.t ............... ok
t/05_preferred_int.t ........ ok
t/06_stream_unpack2.t ....... ok
t/07_break.t ................ ok
t/08_cycle.t ................ ok
t/09_stddata.t .............. ok
t/10_splitted_bytes.t ....... ok
t/11_stream_unpack3.t ....... ok
t/12_stream_unpack4.t ....... ok
t/13_booleans.t ............. ok
t/14_invalid_data.t ......... ok
t/15_utf8.t ................. ok
t/16_unpacker_for_larges.t .. ok
t/17_canonical.t ............ ok
t/18_new_interface.t ........ ok
t/19_utf8_property.t ........ ok
t/20_de.t ................... ok
t/21_dirty_float.t .......... ok
t/22_pid_pack_unpack.t ...... ok
t/23-empty-key.t ............ ok
t/24_tied.t ................. ok
t/40_threads.t .............. ok
t/50_leaktrace.t ............ skipped: Test requires module 'Test::LeakTrace' but it's not found
All tests successful.
Test Summary Report
-------------------
t/23-empty-key.t (Wstat: 0 Tests: 3 Failed: 0)
TODO passed: 1-2
Files=27, Tests=629, 1 wallclock secs ( 0.20 usr 0.06 sys + 0.88 cusr 0.12 csys = 1.26 CPU)
Result: PASS
And output of my test script is same as older Perls.
SV = PVNV(0x7f81d3005b70) at 0x7f81d302d8b8
REFCNT = 1
FLAGS = (PADMY,NOK,POK,pNOK,pPOK)
IV = 0
NV = 3
PV = 0x7f81d2c0e2e0 "3"\0
CUR = 1
LEN = 16
This is an interesting internal change. It looks that the internal SV upgrade no longer occurs.
Is it caused by new cow? https://metacpan.org/module/DAGOLDEN/perl-5.19.1/pod/perldelta.pod#Internal-Changes
tokuhirom
On Mon, Jul 1, 2013 at 2:11 AM, Fuji, Goro [email protected] wrote:
This is an interesting internal change. It looks that the internal SV upgrade no longer occurs.
— Reply to this email directly or view it on GitHubhttps://github.com/msgpack/msgpack-perl/issues/14#issuecomment-20250641 .
@gfx will send mail to p5p.