| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
| |
During v5.29.8 dev cycle a change was made to Devel-PPPort
18d728ac3b which justify to bump and release a new
version of Devel::PPPort.
|
| |
|
|
|
|
|
|
|
|
| |
Without this change corelist-perldelta.pl would not see the
changes from XS::APItest.
./perl -Ilib Porting/corelist-perldelta.pl \
--mode=update pod/perldelta.pod
|
| |
|
|
|
|
|
| |
Update perldelta file with recent changes
and perform some extra cleanup.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This configuration is going to considerably slowing
down smokes but this is a useful alternate when
preparing a release.
We can probably consider commenting these extra config
and only check them for release. Or we could also provide
two travis.yaml:
- .travis.yml.light
- .travis.yml.full
And use a symlink depending which one we want to use.
|
|
|
|
|
| |
Add note concerning the bump of PERL_API_* constants
for blead point releases.
|
|
|
|
|
| |
Also bump Porting/Maintainers.pl to synchronize
with the upstream version we are using.
|
|
|
|
| |
It should use errsv value from passed argument.
|
| |
|
| |
|
|
|
|
|
|
|
| |
When the protocol passed to socket() is unknown, set errno to
WSAEPROTONOSUPPORT.
[perl #133853]
|
|\
| |
| |
| |
| |
| | |
PERL_GLOBAL_STRUCT and DPERL_GLOBAL_STRUCT_PRIVATE builds haven't been
smoked for quite a while and the code has bit-rotted. The commits in
this branch made them build and all test pass again, at least on Linux
|
| |
| |
| |
| |
| |
| |
| |
| | |
There are two separate copies of this function, chosen by
the presence of PERL_GLOBAL_STRUCT_PRIVATE. The previous couple of
commits have made them more similar; this commit merges them into a
single function with differing blocks of code protected by
PERL_GLOBAL_STRUCT_PRIVATE
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
In the PERL_GLOBAL_STRUCT_PRIVATE variant of this code, it zeroes out
unused slots of a freshly-realloced PL_my_cxt_list[]. This is not
necessary, as those slots won't be used until a new index is allocated,
as which point the new slot will get written to before anything else.
The non-PERL_GLOBAL_STRUCT_PRIVATE variant of this function doesn't have
this redundant zeroing.
So remove it.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
There are two separate copies of this function, chosen by
the presence of PERL_GLOBAL_STRUCT_PRIVATE.
Make the two versions closer to each other, to allow shortly for
merging.
Mainly its renaming the int pointer parameter from 'index' to 'indexp',
and adding a local var 'index', which is assigned from *indexp where
appropriate.
Also harmonise some of the comments between the two functions.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Under PERL_GLOBAL_STRUCT, all the "global" vars are put in a structure,
which means perlvars.h needs a similar constraint to intrpvar.h:
its size and alignment shouldn't change between debugging and
non-debugging builds. This is because regcomp/exec.c are compiled both
with and without DEBUGGING.
[Fixed by Karl]
|
| |
| |
| |
| |
| | |
This var was protected by PERL_GLOBAL_STRUCT_PRIVATE, but
PERL_GLOBAL_STRUCT doesn't allow static vars either.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Under PERL_GLOBAL_STRUCT (well, actually I've only tried under
PERL_GLOBAL_STRUCT_PRIVATE), cpan/ExtUtils-MakeMaker/t/03-xsstatic.t
was failing some tests. This was because it was creating a
statically-linked perl binary, but wasn't compiling perlmain.c with
-DPERL_CORE. Usually this doesn't matter, but under PERL_GLOBAL_STRUCT
it needed a definition of aTHX which it was pulling from XSUB.h rather
than perl.h, causing a SEGV.
Until a proper fix makes it way into MakeMaker, explicitly define
PERL_CORE in perlmain.c
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
The MY_CXT subsystem allows per-thread pseudo-static data storage.
Part of the implementation for this involves each XS module being
assigned a unique index in its my_cxt_index static var when first
loaded.
Because PERL_GLOBAL_STRUCT bans any static vars, under those builds
there is instead a table which maps the MY_CXT_KEY identifying string to
index.
Unfortunately, this table was allocated per-interpreter rather than
globally, meaning if multiple threads tried to load the same XS module,
crashes could ensue.
This manifested itself in failures in
ext/XS-APItest/t/keyword_plugin_threads.t
The fix is relatively straightforward: allocate PL_my_cxt_keys globally
rather than per-interpreter.
Also record the size of this struct in a new var, PL_my_cxt_keys_size,
rather than doing double duty on PL_my_cxt_size.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
(Found by code inspection - I can't reproduce a failure)
the MY_CXT subsystem, which allows per-thread pseudo-static variables,
has a thread race condition.
When a module is first loaded, it is allocated unique index (from
PL_my_cxt_index++) which is assigned to the module's my_cxt_index static
var.
If two threads both try to load an XS module at the same time, its
possible for one thread to set my_cxtp, then a second thread to overwrite
it with a higher value, causing the first thread to use the wrong index
into its local storage.
|
| |
| |
| |
| |
| | |
Valgrind wasn't happy, as this global var wasn't being initialised to
NULL.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Fix the various Perl_PerlSock_dup2_cloexec() type functions so that
t/porting/liberl.a passes under -DPERL_GLOBAL_STRUCT_PRIVATE builds.
In these builds it is forbidden to have any static variables, but each
of these functions (via convoluted macros) has a static var called
'strategy' which records, for each function, whether a run-time probe
has been done to determine the best way of achieving close-exec
functionality, and the result.
Replace them all with 'global' vars: PL_strategy_dup2 etc.
NB these vars aren't thread-safe but it doesn't really matter, as the
worst that can happen is for a redundant probe or two to be done before
a suitable "don't probe any more" value is written to the var and seen
by all the threads.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
change a couple of
const char * foo[] = { ... }
to
const char * const foo[] = { ... }
Making the string ptrs const means the whole thing is RO and doesn't
appear in data section, making porting/libperl.t happier when building
under -DPERL_GLOBAL_STRUCT_PRIVATE.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This file only needs including by globals.c; it was being included
in regcomp.c too as the declarations in regcomp.h aren't included by
perl.h and thus don't get pulled into globals.c. This was a confusing
and hacky workaround.
Instead, this commit causes globals.c to #include regcomp.h directly
After this commit, only globals.c #includes INTERN.h
|
| |
| |
| |
| |
| |
| |
| |
| | |
This file really only needs including by globals.c - including it in
sdbm.c was probably just a thinko or cut and paste error from decades ago.
Removing it doesn't seem to break anything.
After this commit, only globals.c and regcomp.c include it.
|
| |
| |
| |
| |
| |
| |
| |
| | |
The perl build option -DPERL_GLOBAL_STRUCT_PRIVATE had bit-rotted
due to lack of smoking. This commit and the next fix it.
I've separated out the vutil.c change into a separate commit since
this file is actually part of the 'version' CPAN distribution and
normally should be edited upstream first.
|
|/
|
|
|
|
| |
The perl build option -DPERL_GLOBAL_STRUCT_PRIVATE had bit-rotted
due to lack of smoking. The main fix is to just add 'dVAR;' to any
functions which have a pTHX arg. It's a NOOP on normal builds.
|
|
|
|
|
|
|
|
|
|
| |
This new test script has a test that's supposed to exercise an up-to 10s
wait-and-retry loop when loading properties. It has a 500s timeout
built-in for if that fails. On my system its been intermittently
failing (not sure if due to something I'm doing or a problem with the
test or with regcomp.c) which effectively hangs the test run.
So decrease the timeout to 25 secs.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
1.9760 is now released to CPAN to match its status
in blead.
This commit is synchronizing the Changelog, by reintroducing
some history which were lost during previous reverts.
Any new change since cf8375d should now go to the next release 1.9761.
A '{{NEXT}}' entry was added to the Changes for tracking these changes.
Note that a Dual-Life git repository is now available for Time-HiRes.
Upstream-URL: https://github.com/Dual-Life/Time-HiRes
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
These are in a generated structure.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Without doing this, it is possible that the behavior is undefined when
subtracting two pointers that point to the same object.
See thread beginning at
http://nntp.perl.org/group/perl.perl5.porters/251541
In particular this from Tomasz Konojacki
C11 says:
> When two pointers are subtracted, both shall point to elements of the
> same array object, or one past the last element of the array object;
> the result is the difference of the subscripts of the two array
> elements. The size of the result is implementation-defined, and its
> type (a signed integer type) is ptrdiff_t defined in the <stddef.h>
> header. If the result is not representable in an object of that type,
> the behavior is undefined.
There are many ways to interpret this passage, but according to (most?)
C compilers developers, it means that no object can be larger than
PTRDIFF_MAX. For example, gcc's optimizer assummes that strlen() will
never return anything larger than PTRDIFF_MAX [1].
There's also a blogpost[2] on this topic, which IMO is a very
interesting read.
If gcc and clang can assume that all objects won't be larger than
PTRDIFF_MAX, so can we. Also, in practice, ssize_t and ptrdiff_t on most
(all?) platforms are defined as exactly the same type.
BTW, the fact that compilers assume that objects can't be larger than
PTRDIFF_MAX has very dangerous implications on 32-bit platforms. Is it
possible to create string longer than PTRDIFF_MAX on 32-bit perls?. It
shouldn't be allowed.
[1] - https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78153
[2] - https://trust-in-soft.com/objects-larger-than-ptrdiff_max-bytes/
|
|
|
|
|
| |
While single stepping in gdb, I noticed that this loop kept executing,
when it need not.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The failing case can be reduced to
qr/\x{100}[\x{3030}\x{1fb2}/
(It only happens on UTF-8 patterns).
The bottom line is that it was assuming that there was at least one
character that folded to 1fb2 besides itself, even though the function
call said there weren't any such. The solution is to pay attention to
the function return value.
I incorporated Hugo's++ patch as part of this one.
However, the original test case should never have gotten this far. The
parser is getting passed garbage, and instead of croaking, it is somehow
interpreting it as valid and calling the regex compiler. I will file a
ticket about that.
|
|
|
|
|
|
|
|
|
|
|
| |
The problem here is that a syntax error occurs and hence certain things
don't get done, but processing continues, as the error isn't checked for
until after the return of the function that found it. The failing
assertion is checking that those certain things actually did get done.
There appear to be good reasons to defer the raising of the error until
then, so the simplest way to fix this is to generalize the code so that
the failing assertion doesn't happen.
|
| |
|
| |
|
|
|
|
|
| |
Better to have the build fail if they're wrong than relying on the
code path being hit at runtime in a DEBUGGING build.
|
|\
| |
| |
| |
| |
| |
| | |
This branch moves the handling of user-defined \p{} properties from
lib/utf8_heavy.pl into regcomp.c (rewriting it in C). This fixes a
bunch of bugs, and removes all uses of swashes from regular expression
compilation and execution.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This removes the most obvious and easy things that are no longer needed
since regexes no longer use swashes at all.
tr/// continues, for the time being, to use swashes, so not all swash
handling is removable now. But tr/// doesn't use inversion lists, and
so a bunch of code is ripped out here. Other code could have been, but
I did only the relatively easy stuff. The rest can be ripped out all at
once when tr/// is stops using swashes.
|
| |
| |
| |
| |
| | |
The element at say, [0] is a particular thing. This commit changes to
use a mnemonic instead of [0], for clarity
|
| |
| |
| |
| | |
An empty entry is now just NULL.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
A swash is no longer used, so we can remove some elements from the array
of data that gets stored with the compiled pattern for use in runtime
matching. This is the first step in more simplifications.
Since a swash isn't used, this change also requires regexec.c to change
to use a straight inversion list lookup. This has the salutary effect
of eliminating a conversion between code point and UTF-8.
|