@@ -927,16 +927,27 @@ perl_construct resets it to C<0>.
927927
928928Now suppose we have more than one interpreter instance running at the
929929same time. This is feasible, but only if you used the Configure option
930- C<-Dusemultiplicity> or the options C<-Dusethreads -Duseithreads> when
931- building perl. By default, enabling one of these Configure options
932- sets the per-interpreter global variable C<PL_perl_destruct_level> to
933- C<1>, so that thorough cleaning is automatic and interpreter variables
934- are initialized correctly. Even if you don't intend to run two or
935- more interpreters at the same time, but to run them sequentially, like
936- in the above example, it is recommended to build perl with the
937- C<-Dusemultiplicity> option otherwise some interpreter variables may
938- not be initialized correctly between consecutive runs and your
939- application may crash.
930+ C<-Dusemultiplicity> or either of the options C<-Dusethreads
931+ -Duseithreads> when building perl. By default, enabling one of these
932+ Configure options sets the per-interpreter global variable
933+ C<PL_perl_destruct_level> to C<1>, so that thorough cleaning is
934+ automatic and interpreter variables are initialized correctly. Even if
935+ you don't intend to run two or more interpreters at the same time, but
936+ to run them sequentially, like in the above example, it is recommended
937+ to build perl with the C<-Dusemultiplicity> option otherwise some
938+ interpreter variables may not be initialized correctly between
939+ consecutive runs and your application may crash.
940+
941+ (It used to be that there were two forms of threads, with C<ithreads>
942+ appearing later. But C<ithreads> proved to be superior, and support for
943+ the older model was removed in Perl v5.10. But the documentation and
944+ code have never been purged of the earlier terminology; and perhaps some
945+ newer model will come along to supplant C<ithreads>, so it seems best to
946+ retain both. If you don't care about the threading model used, use
947+ plain C<usethreads> to protect your code from having to change with future
948+ developments. If your code is dependent on the C<ithreads> model, use
949+ C<useithreads> to make sure you will always get that. This applies as well
950+ to the C language symbols C<USE_THREADS> and C<USE_ITHREADS>.)
940951
941952See also L<perlclib/Dealing with embedded perls and threads>.
942953
0 commit comments