=head1 NAME
perl56delta - what's new for perl v5.6.0
=head1 DESCRIPTION
This document describes differences between the 5.005 release and the 5.6.0
release.
=head1 Core Enhancements
=head2 Interpreter cloning, threads, and concurrency
Perl 5.6.0 introduces the beginnings of support for running multiple
interpreters concurrently in different threads. In conjunction with
the perl_clone() API call, which can be used to selectively duplicate
the state of any given interpreter, it is possible to compile a
piece of code once in an interpreter, clone that interpreter
one or more times, and run all the resulting interpreters in distinct
threads.
On the Windows platform, this feature is used to emulate fork() at the
interpreter level. See L for details about that.
This feature is still in evolution. It is eventually meant to be used
to selectively clone a subroutine and data reachable from that
subroutine in a separate interpreter and run the cloned subroutine
in a separate thread. Since there is no shared data between the
interpreters, little or no locking will be needed (unless parts of
the symbol table are explicitly shared). This is obviously intended
to be an easy-to-use replacement for the existing threads support.
Support for cloning interpreters and interpreter concurrency can be
enabled using the -Dusethreads Configure option (see win32/Makefile for
how to enable it on Windows.) The resulting perl executable will be
functionally identical to one that was built with -Dmultiplicity, but
the perl_clone() API call will only be available in the former.
-Dusethreads enables the cpp macro USE_ITHREADS by default, which in turn
enables Perl source code changes that provide a clear separation between
the op tree and the data it operates with. The former is immutable, and
can therefore be shared between an interpreter and all of its clones,
while the latter is considered local to each interpreter, and is therefore
copied for each clone.
Note that building Perl with the -Dusemultiplicity Configure option
is adequate if you wish to run multiple B interpreters
concurrently in different threads. -Dusethreads only provides the
additional functionality of the perl_clone() API call and other
support for running B interpreters concurrently.
NOTE: This is an experimental feature. Implementation details are
subject to change.
=head2 Lexically scoped warning categories
You can now control the granularity of warnings emitted by perl at a finer
level using the C