-
Notifications
You must be signed in to change notification settings - Fork 577
Clarify build options in perlembed doc #15573
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
Comments
From [email protected]https://metacpan.org/source/RJBS/perl-5.24.0/pod/perlembed.pod#L920 At above lines in perlembed doc it mentions options "-Dusethreads btw, while that paragraph at Thanks, |
From @jkeenanOn Wed Aug 31 05:57:30 2016, zhouzhen1@gmail.com wrote:
I should note that these lines are unchanged since 2001.
Actually, 'useithreads' is extensively discussed in pod/perlthrtut.pod.
What is your source for the equivalence of "-Dusethreads" and "-Duseithreads"? (I'm not enough of a threads user/expert to confirm that statement. I do know that when I do smoke tests for FreeBSD, I include '-Duseithreads' because that's how the system perl on that OS is configured.)
I suspect you are correct, but I think we need input from people who know more about threads than I do.
Again, need comment from more informed people.
-- |
The RT System itself - Status changed from 'new' to 'open' |
From [email protected]
IMHO while these lines are still effective today, they actually can be updated.
That doc has also not been updated for long I guess. I believe today both $Config{useithreads} and $Config{usethreads} Since Perl 5.6 (https://metacpan.org/source/GSAR/perl-5.6.0/INSTALL#L623)
I read the Configure script of Perl source. Also there are below links indicating it's not just me find it On 9/2/16, James E Keenan via RT <perlbug-followup@perl.org> wrote:
-- |
From @jkeenanOn Sat Sep 03 00:26:37 2016, zhouzhen1@gmail.com wrote:
In blead, if you configure with '-Dusethreads' only, you will get in %Config: ##### However, to further muddy the waters, in the output of './perl -Ilib -V', you will only get: ##### That is, you will *not* get an entry for 'usethreads' in the output of './perl -Ilib -V'. (It is that output which the Perl 5 Porters request as part of bug reports.) In any event, I agree that for someone trying to embed 'perl', it would probably be less confusing to be told to say '-Dusethreads'. I am attaching a patch for that purpose. Please review. The second point raised by the OP still needs discussion by others. Thank you very much. -- |
From @jkeenan129151-0001-Dusethreads-and-Duseithreads-are-now-equivalent.patchFrom d37ee6359f609a9d9fab7f69dd3a9543aa25e416 Mon Sep 17 00:00:00 2001
From: James E Keenan <[email protected]>
Date: Sat, 3 Sep 2016 12:04:50 -0400
Subject: [PATCH] '-Dusethreads' and '-Duseithreads' are now equivalent.
So, to reduce confusion for users trying to embed perl, mention only the
former, as it's more self-documenting (even though only 'useithreads=define'
is what currently shows up in 'perl -V').
Per recommendation by Zhenyi Zhou. For RT #129151.
---
pod/perlembed.pod | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/pod/perlembed.pod b/pod/perlembed.pod
index 7bc7a8c..a9b36f2 100644
--- a/pod/perlembed.pod
+++ b/pod/perlembed.pod
@@ -917,7 +917,7 @@ perl_construct resets it to C<0>.
Now suppose we have more than one interpreter instance running at the
same time. This is feasible, but only if you used the Configure option
-C<-Dusemultiplicity> or the options C<-Dusethreads -Duseithreads> when
+C<-Dusemultiplicity> or the option C<-Dusethreads> when
building perl. By default, enabling one of these Configure options
sets the per-interpreter global variable C<PL_perl_destruct_level> to
C<1>, so that thorough cleaning is automatic and interpreter variables
@@ -930,7 +930,7 @@ application may crash.
See also L<perlxs/Thread-aware system interfaces>.
-Using C<-Dusethreads -Duseithreads> rather than C<-Dusemultiplicity>
+Using C<-Dusethreads> rather than C<-Dusemultiplicity>
is more appropriate if you intend to run multiple interpreters
concurrently in different threads, because it enables support for
linking in the thread libraries of your system with the interpreter.
--
2.7.4
|
From @jkeenanOn Sat Sep 03 00:26:37 2016, zhouzhen1@gmail.com wrote:
In blead, if you configure with '-Dusethreads' only, you will get in %Config: ##### However, to further muddy the waters, in the output of './perl -Ilib -V', you will only get: ##### That is, you will *not* get an entry for 'usethreads' in the output of './perl -Ilib -V'. (It is that output which the Perl 5 Porters request as part of bug reports.) In any event, I agree that for someone trying to embed 'perl', it would probably be less confusing to be told to say '-Dusethreads'. I am attaching a patch for that purpose. Please review. The second point raised by the OP still needs discussion by others. Thank you very much. -- |
From @jkeenan129151-0001-Dusethreads-and-Duseithreads-are-now-equivalent.patchFrom d37ee6359f609a9d9fab7f69dd3a9543aa25e416 Mon Sep 17 00:00:00 2001
From: James E Keenan <[email protected]>
Date: Sat, 3 Sep 2016 12:04:50 -0400
Subject: [PATCH] '-Dusethreads' and '-Duseithreads' are now equivalent.
So, to reduce confusion for users trying to embed perl, mention only the
former, as it's more self-documenting (even though only 'useithreads=define'
is what currently shows up in 'perl -V').
Per recommendation by Zhenyi Zhou. For RT #129151.
---
pod/perlembed.pod | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/pod/perlembed.pod b/pod/perlembed.pod
index 7bc7a8c..a9b36f2 100644
--- a/pod/perlembed.pod
+++ b/pod/perlembed.pod
@@ -917,7 +917,7 @@ perl_construct resets it to C<0>.
Now suppose we have more than one interpreter instance running at the
same time. This is feasible, but only if you used the Configure option
-C<-Dusemultiplicity> or the options C<-Dusethreads -Duseithreads> when
+C<-Dusemultiplicity> or the option C<-Dusethreads> when
building perl. By default, enabling one of these Configure options
sets the per-interpreter global variable C<PL_perl_destruct_level> to
C<1>, so that thorough cleaning is automatic and interpreter variables
@@ -930,7 +930,7 @@ application may crash.
See also L<perlxs/Thread-aware system interfaces>.
-Using C<-Dusethreads -Duseithreads> rather than C<-Dusemultiplicity>
+Using C<-Dusethreads> rather than C<-Dusemultiplicity>
is more appropriate if you intend to run multiple interpreters
concurrently in different threads, because it enables support for
linking in the thread libraries of your system with the interpreter.
--
2.7.4
|
From @craigberryOn Thu, Sep 1, 2016 at 5:59 PM, James E Keenan via RT
The authority on what's configurable is Configure. See: http://perl5.git.perl.org/perl.git/blob/HEAD:/Configure#l4376 Interpreter threads have long been the only option for threads, |
Migrated from rt.perl.org#129151 (status was 'open')
Searchable as RT129151$
The text was updated successfully, but these errors were encountered: