Vincent Pit [Thu, 14 May 2015 15:38:01 +0000 (17:38 +0200)]
Make sure gv ops seen by multideref are cleaned from the global table
Since they are created in the peephole optimizer, multideref ops have to
rely on getting the lexical scope hints from their first kid. It might have
happened that the kid of one such op was a gv op compiled in the scope of
the pragma, and was then reused outside of the scope of the pragma again
as the first kid of another multideref op. In that case, the multideref op
was wrongly replaced. This is solved by always clearing gv ops entries in
ck_rv2xv() from the global op map.
This solves random failures of test 12 from t/40-scope.t.
Vincent Pit [Tue, 24 Mar 2015 19:54:30 +0000 (16:54 -0300)]
Update the ActivePerl/gcc-3.4 hack for EUMM 7.04
Starting from this version, PERL_ARCHIVE is quoted so we can no longer set
it to the empty string. Instead, we remove all occurrences of PERL_ARCHIVE
in the linking step section of the Makefile, which is OK since we specify
the perl DLL in other variables. This new technique is still valid for
older versions of EUMM.
Vincent Pit [Sat, 12 Jul 2014 16:53:52 +0000 (18:53 +0200)]
In the rpeep replacement, don't check every op for recursion
When the rpeep is available (i.e. starting from perl 5.13.4), recursion in
the peephole optimizer replacement seemingly only happens for static
infinite loops (think for (;;) { }), even though the 'seen' pointer table
is checked for every op. This may cause slowdowns even outside of the scope
of the pragma. To mitigate this problem, only check for recursion on
nextstate, dbstate, and stub ops, since one of those three kind of ops must
occur in any loop/block (respectively for non-empty, non-empty debugging
and empty loops).
Vincent Pit [Tue, 6 Aug 2013 03:26:38 +0000 (00:26 -0300)]
Get rid of t/99-kwalitee.t
New versions started to throw warnings if specific environment variables
are not set. This may be appropriate for dist manager users, but not really
for the rest of the world.
Since kwalitee metrics are either obvious or useless, there's no big loss
in removing this test anyway.
Vincent Pit [Fri, 2 Nov 2012 00:27:25 +0000 (22:27 -0200)]
Don't run the POD spelling test in taint mode
This causes the test to crash on perl 5.12 and below with sensitive
architectures like FreeBSD. Ultimately the root of the issue seems to have
been https://rt.perl.org/rt3/Public/Bug/Display.html?id=60378.
Vincent Pit [Fri, 11 Nov 2011 18:41:17 +0000 (19:41 +0100)]
Threads tests may not be able to spawn all the threads
To work around this :
- move all the threads boilerplate to a new helper test module ;
- capture the warnings/errors that threads->create may throw and reprint
them properly as diagnostics ;
- use Test::Leaner instead of Test::More, as older Test::More sometimes
cause out of sequence bugs ;
- last but not least, do not hardcode the plan and use done_testing with
the actual number of spawned threads instead.
Vincent Pit [Tue, 4 Jan 2011 18:10:07 +0000 (19:10 +0100)]
Always skip seen ops in our peep replacement
Sometimes, there are loops in the next chain as e.g. with infinite loops
like "for (;;) { ... }". We can't reuse the op_opt member because it's
almost always set after the first pass.
Vincent Pit [Fri, 31 Dec 2010 14:05:15 +0000 (15:05 +0100)]
Fix rare segfaults and bugs with threads
There was a race in the "PL_ppaddr[OP_PADSV] save/restore dance" in that
perl might be compiling ops inside and outside the scope of the pragma at
the same time. We solve this by setting the op_ppaddr member of PADSV ops
to a_pp_deref during the peephole optimization phase.
Vincent Pit [Wed, 29 Dec 2010 23:25:59 +0000 (00:25 +0100)]
Force linking against the perl dll when using gcc 3.4 on Windows
When a Windows perl links an XS shared object to an import library using
gcc/g++ version 3.4.x, strange breakage happens at load time because the
mutex-related symbols seems not to be reachable. This situation happens
especially for AS perl and the default compiler suite it installs.
We fix this by forcing g++ to link against the dll instead, which should
be in the same directory as the perl executable (at least for AS perl).
This change is the integration of commit 14f8af2 from Variable::Magic's
repository.