Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bleadperl v5.19.0-246-g13b0f67 breaks LEONT/File-Map-0.57.tar.gz #13080

Closed
p5pRT opened this issue Jul 4, 2013 · 10 comments
Closed

Bleadperl v5.19.0-246-g13b0f67 breaks LEONT/File-Map-0.57.tar.gz #13080

p5pRT opened this issue Jul 4, 2013 · 10 comments

Comments

@p5pRT
Copy link

p5pRT commented Jul 4, 2013

Migrated from rt.perl.org#118747 (status was 'resolved')

Searchable as RT118747$

@p5pRT
Copy link
Author

p5pRT commented Jul 4, 2013

From @andk

git bisect


13b0f67 is the first bad commit
commit 13b0f67
Author​: David Mitchell <davem@​iabyn.com>
Date​: Wed May 22 16​:38​:29 2013 +0100

  re-enable Copy-on-Write by default.

sample fail report


http​://www.cpantesters.org/cpan/report/2c57d796-c6d6-11e2-954c-7bff979cd64d

perl -V


Summary of my perl5 (revision 5 version 19 subversion 1) configuration​: |
  Commit id​: 13b0f67 |
  Platform​: |
  osname=linux, osvers=3.9-1-amd64, archname=x86_64-linux-ld |
  uname='linux k83 3.9-1-amd64 #1 smp debian 3.9.8-1 x86_64 gnulinux ' |
  config_args='-Dprefix=/home/sand/src/perl/repoperls/installed-perls/perl/v5.|
19.0-246-g13b0f67/127e -Dmyhostname=k83 -Dinstallusrbinperl=n -Uversiononly -Dus|
edevel -des -Ui_db -Uuseithreads -Duselongdouble -DDEBUGGING=-g' |
  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=define |
  usemymalloc=n, bincompat5005=undef
  Compiler​:
  cc='cc', ccflags ='-fno-strict-aliasing -pipe -fstack-protector -I/usr/local
/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64',
  optimize='-O2 -g',
  cppflags='-fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include'
  ccversion='', gccversion='4.8.1', 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='long double', nvsize=16, Off_t='off_t', lse
eksize=8
  alignbytes=16, prototype=define
  Linker and Libraries​:
  ld='cc', ldflags =' -fstack-protector -L/usr/local/lib'
  libpth=/usr/local/lib /lib/x86_64-linux-gnu /lib/../lib /usr/lib/x86_64-linu
x-gnu /usr/lib/../lib /lib /usr/lib
  libs=-lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat
  perllibs=-lnsl -ldl -lm -lcrypt -lutil -lc
  libc=, so=so, useshrplib=false, libperl=libperl.a
  gnulibc_version='2.17'
  Dynamic Linking​:
  dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='-Wl,-E'
  cccdlflags='-fPIC', lddlflags='-shared -O2 -g -L/usr/local/lib -fstack-prote
ctor'
 
 
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_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_LONG_DOUBLE USE_PERLIO
  USE_PERL_ATOF
  Built under linux
  Compiled at Jul 4 2013 08​:11​:52
  @​INC​:
  /home/sand/src/perl/repoperls/installed-perls/perl/v5.19.0-246-g13b0f67/127e
/lib/site_perl/5.19.1/x86_64-linux-ld
  /home/sand/src/perl/repoperls/installed-perls/perl/v5.19.0-246-g13b0f67/127e
/lib/site_perl/5.19.1
  /home/sand/src/perl/repoperls/installed-perls/perl/v5.19.0-246-g13b0f67/127e
/lib/5.19.1/x86_64-linux-ld
  /home/sand/src/perl/repoperls/installed-perls/perl/v5.19.0-246-g13b0f67/127e
/lib/5.19.1
  .

--
andreas

@p5pRT
Copy link
Author

p5pRT commented Jul 4, 2013

From @Leont

On Thu, Jul 4, 2013 at 8​:28 AM, Andreas J. Koenig via RT
<perlbug-followup@​perl.org> wrote​:

# New Ticket Created by (Andreas J. Koenig)
# Please include the string​: [perl #118747]
# in the subject line of all future correspondence about this issue.
# <URL​: https://rt-archive.perl.org/perl5/Ticket/Display.html?id=118747 >

git bisect
----------
13b0f67 is the first bad commit
commit 13b0f67
Author​: David Mitchell <davem@​iabyn.com>
Date​: Wed May 22 16​:38​:29 2013 +0100

re\-enable Copy\-on\-Write by default\.

sample fail report
------------------
http​://www.cpantesters.org/cpan/report/2c57d796-c6d6-11e2-954c-7bff979cd64d

Yeah, or better said blead re-breaks it, for previously discussed
reasons (s/foo/bar/ should not reallocate the buffer to make it COW).

Leon

@p5pRT
Copy link
Author

p5pRT commented Jul 4, 2013

The RT System itself - Status changed from 'new' to 'open'

@p5pRT
Copy link
Author

p5pRT commented Aug 20, 2013

From @cpansprout

On Thu Jul 04 00​:05​:46 2013, LeonT wrote​:

On Thu, Jul 4, 2013 at 8​:28 AM, Andreas J. Koenig via RT
<perlbug-followup@​perl.org> wrote​:

# New Ticket Created by (Andreas J. Koenig)
# Please include the string​: [perl #118747]
# in the subject line of all future correspondence about this issue.
# <URL​: https://rt-archive.perl.org/perl5/Ticket/Display.html?id=118747 >

git bisect
----------
13b0f67 is the first bad commit
commit 13b0f67
Author​: David Mitchell <davem@​iabyn.com>
Date​: Wed May 22 16​:38​:29 2013 +0100

re\-enable Copy\-on\-Write by default\.

sample fail report
------------------
http​://www.cpantesters.org/cpan/report/2c57d796-c6d6-11e2-954c-
7bff979cd64d

Yeah, or better said blead re-breaks it, for previously discussed
reasons (s/foo/bar/ should not reallocate the buffer to make it COW).

Do you remember which ticket that was in?

--

Father Chrysostomos

@p5pRT
Copy link
Author

p5pRT commented Aug 20, 2013

From @Leont

On Tue, Aug 20, 2013 at 5​:41 PM, Father Chrysostomos via RT <
perlbug-followup@​perl.org> wrote​:

Yeah, or better said blead re-breaks it, for previously discussed
reasons (s/foo/bar/ should not reallocate the buffer to make it COW).

Do you remember which ticket that was in?

It was discussed in #115910

Leon

@p5pRT
Copy link
Author

p5pRT commented Aug 21, 2013

From @cpansprout

On Tue Aug 20 09​:10​:47 2013, LeonT wrote​:

On Tue, Aug 20, 2013 at 5​:41 PM, Father Chrysostomos via RT <
perlbug-followup@​perl.org> wrote​:

Yeah, or better said blead re-breaks it, for previously discussed
reasons (s/foo/bar/ should not reallocate the buffer to make it COW).

Do you remember which ticket that was in?

It was discussed in #115910

Thank you.

’Turns out s/// on SvLEN==0 was already broken​:

$ perl5.18.1 -e 'for(!${\0}) { Internals​::SvREADONLY($_,0); s/1/1/; }'
Bus error​: 10

--

Father Chrysostomos

@p5pRT
Copy link
Author

p5pRT commented Aug 21, 2013

From @cpansprout

On Wed Aug 21 00​:01​:34 2013, sprout wrote​:

On Tue Aug 20 09​:10​:47 2013, LeonT wrote​:

On Tue, Aug 20, 2013 at 5​:41 PM, Father Chrysostomos via RT <
perlbug-followup@​perl.org> wrote​:

Yeah, or better said blead re-breaks it, for previously discussed
reasons (s/foo/bar/ should not reallocate the buffer to make it
COW).

Do you remember which ticket that was in?

It was discussed in #115910

Thank you.

’Turns out s/// on SvLEN==0 was already broken​:

$ perl5.18.1 -e 'for(!${\0}) { Internals​::SvREADONLY($_,0); s/1/1/; }'
Bus error​: 10

Er, please ignore that.

It has to do with this logic​:

  /* can do inplace substitution? */
  if (c
#ifdef PERL_ANY_COW
  && !is_cow
#endif
  && (I32)clen <= RX_MINLENRET(rx)
  && (once || !(r_flags & REXEC_COPY_STR))
  && !(RX_EXTFLAGS(rx) & RXf_NO_INPLACE_SUBST)
  && (!doutf8 || SvUTF8(TARG))
  && !(rpm->op_pmflags & PMf_NONDESTRUCT))
  {

This line prevents the in-place substitution in File​::Map’s tests​:

  && (once || !(r_flags & REXEC_COPY_STR))

r_flags & REXEC_COPY_STR is always true now. File​::Map fails in earlier
perls if $& is mentioned.

I don’t quite understand the logic here.

--

Father Chrysostomos

@p5pRT
Copy link
Author

p5pRT commented Aug 22, 2013

From @cpansprout

On Wed Aug 21 00​:36​:09 2013, sprout wrote​:

It has to do with this logic​:

/\* can do inplace substitution? \*/
if \(c

#ifdef PERL_ANY_COW
&& !is_cow
#endif
&& (I32)clen <= RX_MINLENRET(rx)
&& (once || !(r_flags & REXEC_COPY_STR))
&& !(RX_EXTFLAGS(rx) & RXf_NO_INPLACE_SUBST)
&& (!doutf8 || SvUTF8(TARG))
&& !(rpm->op_pmflags & PMf_NONDESTRUCT))
{

This line prevents the in-place substitution in File​::Map’s tests​:

    && \(once || \!\(r\_flags & REXEC\_COPY\_STR\)\)

r_flags & REXEC_COPY_STR is always true now. File​::Map fails in earlier
perls if $& is mentioned.

I don’t quite understand the logic here.

I don’t think that logic is correct or ever was. Match vars can point
into the buffer copied by the initial regexp match that comes before this.

I removed that line in 1555b32 and File​::Map passes its tests again.

--

Father Chrysostomos

@p5pRT
Copy link
Author

p5pRT commented Aug 22, 2013

@cpansprout - Status changed from 'open' to 'resolved'

@p5pRT p5pRT closed this as completed Aug 22, 2013
@p5pRT
Copy link
Author

p5pRT commented Aug 22, 2013

From @cpansprout

On Wed Aug 21 22​:45​:13 2013, sprout wrote​:

I removed that line in 1555b32 and File​::Map passes its tests again.

That fix turned out to be wrong, so I redid it in 9cefd26.

--

Father Chrysostomos

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant