view release on metacpan or search on metacpan
examples/postifx-policy-server.pl view on Meta::CPAN
123456789
examples/postifx-policy-server.pl view on Meta::CPAN
view all matches for this distribution
113114115116117118119120121122123124125126127128129130131
Listen
=> 10
)
or
die
"Couldn't be a tcp server on port $default_config->{serverport} : $@\n"
;
# Generate a number of listener threads
my
@threads
= ();
for
( 1 ..
$TC
){
my
$thread
= threads->create( \
&process_client
,
$server
);
push
(
@threads
,
$thread
);
}
foreach
my
$thread
(
@threads
){
$thread
->
join
();
}
unlink
(
$pidfile
);
closelog;
exit
( 0 );
view release on metacpan or search on metacpan
21672168216921702171217221732174217521762177no_fh_allowed|||
no_op|||
noperl_die|||vn
not_a_number|||
not_incrementable|||
nothreadhook||5.008000|
nuke_stacks|||
num_overflow|||n
oopsAV|||
oopsHV|||
op_append_elem||5.013006|
46664667466846694670467146724673467446754676#endif
/* Hint: PL_ppaddr
* Calling an op via PL_ppaddr requires passing a context argument
*
for
threaded builds. Since the context argument is different
for
* automatically be
defined
as the correct argument.
*/
#if (PERL_BCDVERSION <= 0x5005005)
51265127512851295130513151325133513451355136#endif
/*
* Boilerplate macros
for
initializing and accessing interpreter-
local
* data from C. All statics in extensions should be reworked to
use
* this,
if
you want to make the extension thread-safe. See ext/re/re.xs
*
* Code that uses these macros is responsible
for
the following:
* 1.
#define MY_CXT_KEY to a unique string, e.g. "DynaLoader_guts"
* 2. Declare a typedef named my_cxt_t that is a structure that contains
51485149515051515152515351545155515651575158
defined
(PERL_CAPI) ||
defined
(PERL_IMPLICIT_CONTEXT)
#ifndef START_MY_CXT
/* This must appear in all extensions that define a my_cxt_t structure,
* right
after
the definition (i.e. at file scope). The non-threads
* case below uses it to declare the data as static. */
#define START_MY_CXT
#if (PERL_BCDVERSION < 0x5004068)
/* Fetches the SV that keeps the per-interpreter data. */
view all matches for this distribution
69806981698269836984698569866987698869896990#else
/* older perls don't have PL_numeric_radix_sv so the radix
* must manually be requested from locale.h
*/
#include <locale.h>
dTHR; /* needed
for
older threaded perls */
struct lconv
*lc
= localeconv();
char
*radix
=
lc
->decimal_point;
if
(radix && IN_LOCALE) {
STRLEN len = strlen(radix);
if
(
*sp
+ len <=
send
&& memEQ(
*sp
, radix, len)) {
view release on metacpan or search on metacpan
examples/rxdebug view on Meta::CPAN
view all matches for this distribution
289290291292293294295296297298299300301302
if
(!
$val
->{tstats}->{waitingForPackets}) {
"not "
;
}
"waiting for packets.\n"
;
if
(
exists
$val
->{tstats}->{nWaiting}) {
"$val->{tstats}->{nWaiting} calls waiting for a thread\n"
;
}
if
(
exists
$val
->{tstats}->{idleThreads}) {
"$val->{tstats}->{idleThreads} threads are idle\n"
;
}
}
# print rxstats if they were returned
if
(
exists
$val
->{rxstats}) {
view release on metacpan or search on metacpan
kafs/kafs.c view on Meta::CPAN
view all matches for this distribution
8485868788899091929394* fail
with
SIGSYS. We therefore set a signal handler that changes a static
* variable
if
SIGSYS is received.
*
* It's really ugly to
do
this in library or PAM module in so many ways.
* Static variables are evil, changing signal handlers out from under an
* application is evil, and the interaction of signals and threads is probably
* nasty. The only things that make this better is that this case will never
* be triggered in the normal case of AFS being loaded and the only
time
that
* we change this static variable is to
say
that the call failed, so there
* shouldn't be a collision of updates from multiple calls.
*
view release on metacpan or search on metacpan
src/inc/Test/Builder.pm view on Meta::CPAN
1112131415161718192021222324252627$VERSION
=
'0.17'
;
$CLASS
= __PACKAGE__;
my
$IsVMS
= $^O eq
'VMS'
;
# Make Test::Builder thread-safe for ithreads.
BEGIN {
if
( $] >= 5.008 &&
$Config
{useithreads} ) {
threads::shared->
import
;
}
else
{
*share
=
sub
{ 0 };
*lock
=
sub
{ 0 };
}
src/inc/Test/Builder.pm view on Meta::CPAN
view all matches for this distribution
765766767768769770771772773774775if
(
$No_Plan
) {
$self
->_print(
"1..$Curr_Test\n"
)
unless
$self
->no_header;
$Expected_Tests
=
$Curr_Test
;
}
# 5.8.0 threads bug. Shared arrays will not be auto-extended
# by a slice. Worse, we have to fill in every entry else
# we'll get an "Invalid value for shared scalar" error
for
my
$idx
(
$#Test_Results
..
$Expected_Tests
-1) {
my
%empty_result
= ();
share(
%empty_result
);
view release on metacpan or search on metacpan
1011121314151617181920_Inline/build/AI/ANN/Neuron_6185/Makefile.PL
_Inline/build/AI/ANN/Neuron_6185/Neuron_6185.xs
_Inline/build/AI/ANN/Neuron_6185/out.Makefile_PL
_Inline/build/AI/ANN/Neuron_6185/out.make
_Inline/build/AI/ANN/Neuron_6185/pm_to_blib
_Inline/config-i686-linux-gnu-thread-multi-5.010001
_Inline/lib/auto/AI/ANN/Neuron_1390/Neuron_1390.inl
_Inline/lib/auto/AI/ANN/Neuron_1390/Neuron_1390.so
_Inline/lib/auto/AI/ANN/Neuron_510f/Neuron_510f.inl
_Inline/lib/auto/AI/ANN/Neuron_510f/Neuron_510f.so
_Inline/lib/auto/AI/ANN/Neuron_69ce/Neuron_69ce.inl
view all matches for this distribution
7576777879808182838485examples/_Inline/build/benchmark_pl_c51b/Makefile.PL
examples/_Inline/build/benchmark_pl_c51b/benchmark_pl_c51b.xs
examples/_Inline/build/benchmark_pl_c51b/out.Makefile_PL
examples/_Inline/build/benchmark_pl_c51b/out.make
examples/_Inline/build/benchmark_pl_c51b/pm_to_blib
examples/_Inline/config-i686-linux-gnu-thread-multi-5.010001
examples/_Inline/lib/auto/AI/ANN/Neuron_1390/Neuron_1390.inl
examples/_Inline/lib/auto/AI/ANN/Neuron_1390/Neuron_1390.so
examples/_Inline/lib/auto/AI/ANN/Neuron_f333/Neuron_f333.inl
examples/_Inline/lib/auto/AI/ANN/Neuron_f333/Neuron_f333.so
examples/_Inline/lib/auto/benchmark_pl_4399/benchmark_pl_4399.inl
view release on metacpan or search on metacpan
lib/AI/Evolve/Befunge.pm view on Meta::CPAN
view all matches for this distribution
62636465666768697071727374757677If you don't know anything about Befunge, I recommend you
read
up on
that first,
before
trying to understand how this works.
The individuals of this population (which we call Critters) may be of
Each one is issued a certain number of
"tokens"
(which you can think
of as blood sugar or battery power). Just being born takes a certain
number of tokens, depending on the code size. After that, doing things
(like executing a befunge command, pushing a value to the stack,
spawning a thread) all take a certain number of tokens to accomplish.
When the number of tokens drops to 0, the critter dies. So it had
better accomplish its task
before
that happens.
After a population fights it out
for
a
while
, the winners are chosen
(who
continue
to live) and everyone
else
dies. Then a new population
view release on metacpan or search on metacpan
17631764176517661767176817691770177117721773ninstr|||
no_bareword_allowed|||
no_fh_allowed|||
no_op|||
not_a_number|||
nothreadhook||5.008000|
nuke_stacks|||
num_overflow|||n
offer_nice_chunk|||
oopsAV|||
oopsCV|||
38273828382938303831383238333834383538363837#endif
/* Hint: PL_ppaddr
* Calling an op via PL_ppaddr requires passing a context argument
*
for
threaded builds. Since the context argument is different
for
* automatically be
defined
as the correct argument.
*/
#if (PERL_BCDVERSION <= 0x5005005)
42364237423842394240424142424243424442454246#endif
/*
* Boilerplate macros
for
initializing and accessing interpreter-
local
* data from C. All statics in extensions should be reworked to
use
* this,
if
you want to make the extension thread-safe. See ext/re/re.xs
*
* Code that uses these macros is responsible
for
the following:
* 1.
#define MY_CXT_KEY to a unique string, e.g. "DynaLoader_guts"
* 2. Declare a typedef named my_cxt_t that is a structure that contains
42584259426042614262426342644265426642674268
defined
(PERL_CAPI) ||
defined
(PERL_IMPLICIT_CONTEXT)
#ifndef START_MY_CXT
/* This must appear in all extensions that define a my_cxt_t structure,
* right
after
the definition (i.e. at file scope). The non-threads
* case below uses it to declare the data as static. */
#define START_MY_CXT
#if (PERL_BCDVERSION < 0x5004068)
/* Fetches the SV that keeps the per-interpreter data. */
view all matches for this distribution
57255726572757285729573057315732573357345735#else
/* older perls don't have PL_numeric_radix_sv so the radix
* must manually be requested from locale.h
*/
#include <locale.h>
dTHR; /* needed
for
older threaded perls */
struct lconv
*lc
= localeconv();
char
*radix
=
lc
->decimal_point;
if
(radix && IN_LOCALE) {
STRLEN len = strlen(radix);
if
(
*sp
+ len <=
send
&& memEQ(
*sp
, radix, len)) {
view release on metacpan or search on metacpan
lib/AI/FuzzyEngine.pm view on Meta::CPAN
93949596979899100101102103104105my
@pdls
=
map
{ PDL::Core::topdl(
$_
) }
@vals
;
# Get size of wrapping piddle (using a trick)
# applying valid expansion rules for element wise operations
my
$zeros
= PDL->pdl(0);
# v-- does not work due to threading mechanisms :-((
# $zeros += $_ for @pdls;
# Avoid threading!
for
my
$p
(
@pdls
) {
croak
"Empty piddles are not allowed"
if
$p
->isempty();
eval
{
$zeros
=
$zeros
+
$p
->zeros(); 1
} or croak
q{Can't expand piddles to same size}
;
}
lib/AI/FuzzyEngine.pm view on Meta::CPAN
218219220221222223224225226227228
my
$green_is_ok
=
$green
->ok();
# Defuzzification ( is a matter of the fuzzy variable )
my
$delta_green
=
$green
->defuzzify();
# -5 ... 5
=head2 Using PDL and its threading capability
use PDL;
use AI::FuzzyEngine;
# (Probably a stupide example)
lib/AI/FuzzyEngine.pm view on Meta::CPAN
276277278279280281282283284285286# [ 0 0.33333333 0.33333333 0.33333333]
# [ 0 0.5 1 1]
# ]
# Defuzzify the output variables
# Caveat: This includes some non-threadable operations up to now
my
$problem_ratings
=
$problem
->defuzzify();
'Problems rated: '
,
$problem_ratings
;
# [
# [ 0 0.60952381 0.60952381 0.60952381]
# [ 0 0.75 1 1]
lib/AI/FuzzyEngine.pm view on Meta::CPAN
view all matches for this distribution
494495496497498499500501502503504505506507508509510511512513514
$zeros
=
$zeros
+
$_
->zeros()
for
@pdls
;
# Expand all piddles
@pdls
=
map
{
$_
+
$zeros
}
@pdls
;
Defuzzification uses some heavy non-threading code,
so there might be a performance penalty
for
big piddles.
=head2 Todos
=over 2
=item Add optional alternative implementations of fuzzy operations
=item More checks on input arguments and allowed method calls
=item PDL awareness: Use threading in C<< $variable->defuzzify >>
=item Divide tests into API tests and test of internal functions
=back
view release on metacpan or search on metacpan
view all matches for this distribution
762763764765766767768769770ppd :
$(NOECHO) $(ECHO)
'<SOFTPKG NAME="$(DISTNAME)" VERSION="0.01">'
> $(DISTNAME).ppd
$(NOECHO) $(ECHO)
' <ABSTRACT>Perl extension for embedding ASP (Answer Set Programming) programs in Perl.</ABSTRACT>'
>> $(DISTNAME).ppd
$(NOECHO) $(ECHO)
' <AUTHOR>leviathan <leviathan@></AUTHOR>'
>> $(DISTNAME).ppd
$(NOECHO) $(ECHO)
' <IMPLEMENTATION>'
>> $(DISTNAME).ppd
$(NOECHO) $(ECHO)
' <ARCHITECTURE NAME="i686-linux-gnu-thread-multi-5.10" />'
>> $(DISTNAME).ppd
$(NOECHO) $(ECHO)
' <CODEBASE HREF="" />'
>> $(DISTNAME).ppd
$(NOECHO) $(ECHO)
' </IMPLEMENTATION>'
>> $(DISTNAME).ppd
$(NOECHO) $(ECHO)
'</SOFTPKG>'
>> $(DISTNAME).ppd
view release on metacpan or search on metacpan
lib/AI/MXNet/Rtc.pm view on Meta::CPAN
view all matches for this distribution
29303132333435363738394041424344454647
Note that this is only the body of the kernel, i.e.
after
{ and
before
}. Rtc will decorate the kernel.
For example,
if
name =
"mykernel"
and
inputs = [(
'x'
, mx.nd.zeros((10,)))]
outputs = [(
'y'
, mx.nd.zeros((10,)))]
kernel =
"y[threadIdx.x] = x[threadIdx.x];"
,
the kernel that is compile will be:
extern
"C"
__global__ mykernel(float
*x
, float
*y
) {
const
int
x_ndim = 1;
const
int
x_dims = { 10 };
const
int
y_ndim = 1;
const
int
y_dims = { 10 };
y[threadIdx.x] = x[threadIdx.x];
}
=cut
has 'handle' => (is => 'rw', isa => 'RtcHandle', init_arg => undef);
has [qw/name kernel/] => (is => 'ro', isa => 'Str', required => 1);
view release on metacpan or search on metacpan
192193194195196197198199200201202* \brief
return
str message of the
last
error
* all function in this file will
return
0
when
success
* and -1
when
an error occured,
* MXGetLastError can be called to retrieve the error
*
* this function is threadsafe and can be called by different thread
* \
return
error info
*/
const char
*MXGetLastError
();
//-------------------------------------
view all matches for this distribution
235236237238239240241242243244245246int
MXSetProfilerState(
int
state);
/*! \brief Save profile and stop profiler */
int
MXDumpProfile();
/*! \brief Set the number of OMP threads to
use
*/
int
MXSetNumOMPThreads(
int
thread_num);
//-------------------------------------
// Part 1: NDArray creation and deletion
//-------------------------------------
/*!
view release on metacpan or search on metacpan
inc/Test/Builder.pm view on Meta::CPAN
10111213141516171819202122232425262728use
strict;
$VERSION
=
'0.72'
;
$VERSION
=
eval
$VERSION
;
# make the alpha version come out as a number
# Make Test::Builder thread-safe for ithreads.
BEGIN {
# Load threads::shared when threads are turned on.
# 5.8.0's threads are so busted we no longer support them.
if
( $] >= 5.008001 &&
$Config
{useithreads} &&
$INC
{
'threads.pm'
}) {
# Hack around YET ANOTHER threads::shared bug. It would
# occassionally forget the contents of the variable when sharing it.
# So we first copy the data, then share, then put our copy back.
*share
=
sub
(\[$@%]) {
my
$type
=
ref
$_
[0];
my
$data
;
inc/Test/Builder.pm view on Meta::CPAN
3839404142434445464748}
else
{
die
(
"Unknown type: "
.
$type
);
}
$_
[0] =
&threads::shared::share
(
$_
[0]);
if
(
$type
eq
'HASH'
) {
%{
$_
[0]} =
%$data
;
}
elsif
(
$type
eq
'ARRAY'
) {
inc/Test/Builder.pm view on Meta::CPAN
5657585960616263646566
}
return
$_
[0];
};
}
# 5.8.0's threads::shared is busted when threads are off
# and earlier Perls just don't have that module at all.
else
{
*share
=
sub
{
return
$_
[0] };
*lock
=
sub
{ 0 };
}
inc/Test/Builder.pm view on Meta::CPAN
view all matches for this distribution
10921093109410951096109710981099110011011102
$self
->{Expected_Tests} =
$self
->{Curr_Test};
}
# Auto-extended arrays and elements which aren't explicitly
# filled in with a shared reference will puke under 5.8.0
# ithreads. So we have to fill them in by hand. :(
my
$empty_result
=
&share
({});
for
my
$idx
( 0..
$self
->{Expected_Tests}-1 ) {
$test_results
->[
$idx
] =
$empty_result
unless
defined
$test_results
->[
$idx
];
}
view release on metacpan or search on metacpan
view all matches for this distribution
5051525354555657585960* \brief
return
str message of the
last
error
* all function in this file will
return
0
when
success
* and -1
when
an error occured,
* NNGetLastError can be called to retrieve the error
*
* this function is threadsafe and can be called by different thread
* \
return
error info
*/
const char
*NNGetLastError
(void);
/*!
* \brief list all the available operator names, include entries.
view release on metacpan or search on metacpan
lib/AI/Ollama/RequestOptions.pm view on Meta::CPAN
view all matches for this distribution
188189190191192193194195196197198199200201202203204has
'num_predict'
=> (
is
=>
'ro'
,
isa
=> Int,
);
=head2 C<< num_thread >>
Sets the number of threads to use during computation. By default, Ollama will detect this for optimal performance. It is recommended to set this value to the number of physical CPU cores your system has (as opposed to the logical number of cores).
=cut
has
'num_thread'
=> (
is
=>
'ro'
,
isa
=> Int,
);
=head2 C<< numa >>
view release on metacpan or search on metacpan
18261827182818291830183118321833183418351836ninstr|||
no_bareword_allowed|||
no_fh_allowed|||
no_op|||
not_a_number|||
nothreadhook||5.008000|
nuke_stacks|||
num_overflow|||n
offer_nice_chunk|||
oopsAV|||
oopsHV|||
40734074407540764077407840794080408140824083#endif
/* Hint: PL_ppaddr
* Calling an op via PL_ppaddr requires passing a context argument
*
for
threaded builds. Since the context argument is different
for
* automatically be
defined
as the correct argument.
*/
#if (PERL_BCDVERSION <= 0x5005005)
45304531453245334534453545364537453845394540#endif
/*
* Boilerplate macros
for
initializing and accessing interpreter-
local
* data from C. All statics in extensions should be reworked to
use
* this,
if
you want to make the extension thread-safe. See ext/re/re.xs
*
* Code that uses these macros is responsible
for
the following:
* 1.
#define MY_CXT_KEY to a unique string, e.g. "DynaLoader_guts"
* 2. Declare a typedef named my_cxt_t that is a structure that contains
45524553455445554556455745584559456045614562
defined
(PERL_CAPI) ||
defined
(PERL_IMPLICIT_CONTEXT)
#ifndef START_MY_CXT
/* This must appear in all extensions that define a my_cxt_t structure,
* right
after
the definition (i.e. at file scope). The non-threads
* case below uses it to declare the data as static. */
#define START_MY_CXT
#if (PERL_BCDVERSION < 0x5004068)
/* Fetches the SV that keeps the per-interpreter data. */
view all matches for this distribution
61356136613761386139614061416142614361446145#else
/* older perls don't have PL_numeric_radix_sv so the radix
* must manually be requested from locale.h
*/
#include <locale.h>
dTHR; /* needed
for
older threaded perls */
struct lconv
*lc
= localeconv();
char
*radix
=
lc
->decimal_point;
if
(radix && IN_LOCALE) {
STRLEN len = strlen(radix);
if
(
*sp
+ len <=
send
&& memEQ(
*sp
, radix, len)) {
view release on metacpan or search on metacpan
lib/AI/Pathfinding/OptimizeMultiple.pm view on Meta::CPAN
view all matches for this distribution
796797798799800801802803804805806=item * L<Freecell Solver|http://fc-solve.shlomifish.org/>
For which this code was first written and used.
=item * L<Alternative Implementation in C#/.NET|https://bitbucket.org/shlomif/fc-solve/src/cc5b428ed9bad0132d7a7bc1a14fc6d3650edf45/fc-solve/presets/soft-threads/meta-moves/auto-gen/optimize-seq?at=master>
An Alternative implementation in C#/.NET, which was written because the
performance of the Perl/PDL code was too slow.
=item * L<PDL> - Perl Data Language
view release on metacpan or search on metacpan
alien_packages/tds/Makefile view on Meta::CPAN
view all matches for this distribution
23456789101112131415161718192021222324# 20170712 Tom Stall
HOST_SYSTEM = $(shell uname | cut -f 1 -d_)
SYSTEM ?= $(HOST_SYSTEM)
CXX = g++
CPPFLAGS += -I/usr/
local
/include -I./ -pthread -fPIC
CXXFLAGS += -std=c++11
ifeq ($(SYSTEM),Darwin)
LDFLAGS += -L/usr/
local
/lib `pkg-config --libs grpc++ grpc` \
-lgrpc++_reflection \
-lprotobuf -lpthread -ldl
else
LDFLAGS += -L/usr/
local
/lib `pkg-config --libs grpc++ ` \
-lprotobuf
endif
SLDFLAGS += -L/usr/
local
/lib `pkg-config --libs grpc++ grpc` \
-Wl,--
no
-as-needed -lgrpc++_reflection -Wl,--as-needed \
-lprotobuf -lpthread -lssl -lcrypto -lz -ldl
PROTOC_CMD = protoc
GRPC_CPP_PLUGIN = grpc_cpp_plugin
GRPC_CPP_PLUGIN_PATH ?= `which $(GRPC_CPP_PLUGIN)`
view release on metacpan or search on metacpan
lib/AI/PredictionClient/CPP/PredictionGrpcCpp.pm view on Meta::CPAN
view all matches for this distribution
12131415161718192021
with
=> [
'Alien::Google::GRPC'
,
'AI::PredictionClient::Alien::TensorFlowServingProtos'
],
version
=>
'0.05'
,
name
=>
'AI::PredictionClient::CPP::PredictionGrpcCpp'
,
TYPEMAPS
=> getcwd .
'/blib/lib/AI/PredictionClient/CPP/Typemaps/more_typemaps_STL_String.txt'
,
LIBS
=>
'-ldl'
,
ccflags
=>
'-std=c++11 -pthread'
;
use
5.010;
use
strict;
use
warnings;
view release on metacpan or search on metacpan
lib/AI/TensorFlow/Libtensorflow/Manual/CAPI.pod view on Meta::CPAN
388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924=head2 TF_StartThread
=over 2
Returns a new thread that is running work_func and is identified
(for debugging/performance-analysis) by thread_name.
The given param (which may be null) is passed to work_func when the thread
starts. In this way, data may be passed from the thread back to the caller.
Caller takes ownership of the result and must call TF_JoinThread on it
eventually.
=back
/* From <tensorflow/c/env.h> */
TF_CAPI_EXPORT extern TF_Thread* TF_StartThread(const TF_ThreadOptions* options,
const char* thread_name,
void (*work_func)(void*),
void* param);
=head2 TF_JoinThread
=over 2
Waits for the given thread to finish execution, then deletes it.
=back
/* From <tensorflow/c/env.h> */
TF_CAPI_EXPORT extern void TF_JoinThread(TF_Thread* thread);
=head2 TF_LoadSharedLibrary
=over 2
lib/AI/TensorFlow/Libtensorflow/Manual/CAPI.pod view on Meta::CPAN
4863486448654866486748684869487048714872=head2 TF_MaybeLockVariableInputMutexesInOrder
=over 2
This is a helper function which acquires mutexes in-order to provide
thread-safe way of performing weights update during the optimizer op. It
returns an opaque LockHolder handle back to plugin. This handle is passed to
the Release API for releasing the locks when the weight update is done. The
caller takes ownership of the `source` and `dest` tensors and is responsible
for freeing them with TF_DeleteTensor.
lib/AI/TensorFlow/Libtensorflow/Manual/CAPI.pod view on Meta::CPAN
50365037503850395040504150425043504450455046=head2 TFE_ContextOptionsSetAsync
=over 2
Sets the default execution mode (sync/async). Note that this can be
overridden per thread using TFE_ContextSetExecutorForThread.
=back
/* From <tensorflow/c/eager/c_api.h> */
TF_CAPI_EXPORT extern void TFE_ContextOptionsSetAsync(TFE_ContextOptions*,
lib/AI/TensorFlow/Libtensorflow/Manual/CAPI.pod view on Meta::CPAN
51105111511251135114511551165117511851195120512151225123=head2 TFE_ContextSetThreadLocalDevicePlacementPolicy
=over 2
Sets a thread-local device placement policy. After this call, other calls to
TFE_Execute in the same thread will use the device policy specified here
instead of the device policy used to construct the context. This has no
effect on the device policy used by other program threads.
=back
/* From <tensorflow/c/eager/c_api.h> */
TF_CAPI_EXPORT extern void TFE_ContextSetThreadLocalDevicePlacementPolicy(
lib/AI/TensorFlow/Libtensorflow/Manual/CAPI.pod view on Meta::CPAN
51265127512851295130513151325133513451355136=head2 TFE_ContextGetDevicePlacementPolicy
=over 2
Returns the device placement policy to be used by this context in the current
thread.
=back
/* From <tensorflow/c/eager/c_api.h> */
TF_CAPI_EXPORT extern TFE_ContextDevicePlacementPolicy
lib/AI/TensorFlow/Libtensorflow/Manual/CAPI.pod view on Meta::CPAN
67806781678267836784678567866787678867896790=head2 TFE_ExecutorWaitForAllPendingNodes
=over 2
Causes the calling thread to block till all ops dispatched in this executor
have been executed. Note that "execution" here refers to kernel execution /
scheduling of copies, etc. Similar to sync execution, it doesn't guarantee
that lower level device queues (like GPU streams) have been flushed.
This call may not block for execution of ops enqueued concurrently with this
lib/AI/TensorFlow/Libtensorflow/Manual/CAPI.pod view on Meta::CPAN
681568166817681868196820682168226823682468256826=head2 TFE_ContextSetExecutorForThread
=over 2
Sets a custom Executor for the current thread. All nodes created by this
thread will be added to this Executor. It will override the current executor.
=back
/* From <tensorflow/c/eager/c_api_experimental.h> */
TF_CAPI_EXPORT extern void TFE_ContextSetExecutorForThread(TFE_Context*,
lib/AI/TensorFlow/Libtensorflow/Manual/CAPI.pod view on Meta::CPAN
68286829683068316832683368346835683668376838=head2 TFE_ContextGetExecutorForThread
=over 2
Returns the Executor for the current thread.
=back
/* From <tensorflow/c/eager/c_api_experimental.h> */
TF_CAPI_EXPORT extern TFE_Executor* TFE_ContextGetExecutorForThread(
lib/AI/TensorFlow/Libtensorflow/Manual/CAPI.pod view on Meta::CPAN
view all matches for this distribution
68756876687768786879688068816882688368846885=head2 TFE_ContextAsyncWait
=over 2
Sync pending nodes in local executors (including the context default executor
and thread executors) and streaming requests to remote executors, and get the
combined status.
=back
/* From <tensorflow/c/eager/c_api_experimental.h> */
view release on metacpan or search on metacpan
lib/AI/XGBoost/CAPI/RAW.pm view on Meta::CPAN
153154155156157158159160161162All functions in this file will
return
0
when
success
and -1
when
an error occurred,
XGBGetLastError can be called to retrieve the error
This function is thread safe and can be called by different thread
Returns string error information
=head2 XGDMatrixCreateFromFile
lib/AI/XGBoost/CAPI/RAW.pm view on Meta::CPAN
view all matches for this distribution
309310311312313314315316317318319320=item out
created dmatrix
=item nthread
number of threads (up to maximum cores available, if <=0 use all cores)
=back
=head2 XGDMatrixSliceDMatrix
view release on metacpan or search on metacpan
15021503150415051506150715081509151015111512ninstr|||
no_bareword_allowed|||
no_fh_allowed|||
no_op|||
not_a_number|||
nothreadhook||5.008000|
nuke_stacks|||
num_overflow|||n
oopsAV|||
oopsCV|||
oopsHV|||
16871688168916901691169216931694169516961697save_scalar|||
save_set_svflags||5.009000|
save_shared_pvref||5.007003|
save_sptr|||
save_svref|||
save_threadsv||5.005000|
save_vptr||5.006000|
savepvn|||
savepv|||
savesharedpv||5.007003|
savestack_grow_cnt||5.008001|
35093510351135123513351435153516351735183519#endif
/*
* Boilerplate macros
for
initializing and accessing interpreter-
local
* data from C. All statics in extensions should be reworked to
use
* this,
if
you want to make the extension thread-safe. See ext/re/re.xs
*
* Code that uses these macros is responsible
for
the following:
* 1.
#define MY_CXT_KEY to a unique string, e.g. "DynaLoader_guts"
* 2. Declare a typedef named my_cxt_t that is a structure that contains
35313532353335343535353635373538353935403541
defined
(PERL_CAPI) ||
defined
(PERL_IMPLICIT_CONTEXT)
#ifndef START_MY_CXT
/* This must appear in all extensions that define a my_cxt_t structure,
* right
after
the definition (i.e. at file scope). The non-threads
* case below uses it to declare the data as static. */
#define START_MY_CXT
#if (PERL_VERSION < 4 || (PERL_VERSION == 4 && PERL_SUBVERSION < 68 ))
/* Fetches the SV that keeps the per-interpreter data. */
view all matches for this distribution
43954396439743984399440044014402440344044405#else
/* older perls don't have PL_numeric_radix_sv so the radix
* must manually be requested from locale.h
*/
#include <locale.h>
dTHR; /* needed
for
older threaded perls */
struct lconv
*lc
= localeconv();
char
*radix
=
lc
->decimal_point;
if
(radix && IN_LOCALE) {
STRLEN len = strlen(radix);
if
(
*sp
+ len <=
send
&& memEQ(
*sp
, radix, len)) {
view release on metacpan or search on metacpan
15021503150415051506150715081509151015111512ninstr|||
no_bareword_allowed|||
no_fh_allowed|||
no_op|||
not_a_number|||
nothreadhook||5.008000|
nuke_stacks|||
num_overflow|||n
oopsAV|||
oopsCV|||
oopsHV|||
16871688168916901691169216931694169516961697save_scalar|||
save_set_svflags||5.009000|
save_shared_pvref||5.007003|
save_sptr|||
save_svref|||
save_threadsv||5.005000|
save_vptr||5.006000|
savepvn|||
savepv|||
savesharedpv||5.007003|
savestack_grow_cnt||5.008001|
35093510351135123513351435153516351735183519#endif
/*
* Boilerplate macros
for
initializing and accessing interpreter-
local
* data from C. All statics in extensions should be reworked to
use
* this,
if
you want to make the extension thread-safe. See ext/re/re.xs
*
* Code that uses these macros is responsible
for
the following:
* 1.
#define MY_CXT_KEY to a unique string, e.g. "DynaLoader_guts"
* 2. Declare a typedef named my_cxt_t that is a structure that contains
35313532353335343535353635373538353935403541
defined
(PERL_CAPI) ||
defined
(PERL_IMPLICIT_CONTEXT)
#ifndef START_MY_CXT
/* This must appear in all extensions that define a my_cxt_t structure,
* right
after
the definition (i.e. at file scope). The non-threads
* case below uses it to declare the data as static. */
#define START_MY_CXT
#if (PERL_VERSION < 4 || (PERL_VERSION == 4 && PERL_SUBVERSION < 68 ))
/* Fetches the SV that keeps the per-interpreter data. */
view all matches for this distribution
43954396439743984399440044014402440344044405#else
/* older perls don't have PL_numeric_radix_sv so the radix
* must manually be requested from locale.h
*/
#include <locale.h>
dTHR; /* needed
for
older threaded perls */
struct lconv
*lc
= localeconv();
char
*radix
=
lc
->decimal_point;
if
(radix && IN_LOCALE) {
STRLEN len = strlen(radix);
if
(
*sp
+ len <=
send
&& memEQ(
*sp
, radix, len)) {
view release on metacpan or search on metacpan
18141815181618171818181918201821182218231824ninstr|||
no_bareword_allowed|||
no_fh_allowed|||
no_op|||
not_a_number|||
nothreadhook||5.008000|
nuke_stacks|||
num_overflow|||n
offer_nice_chunk|||
oopsAV|||
oopsHV|||
40534054405540564057405840594060406140624063#endif
/* Hint: PL_ppaddr
* Calling an op via PL_ppaddr requires passing a context argument
*
for
threaded builds. Since the context argument is different
for
* automatically be
defined
as the correct argument.
*/
#if (PERL_BCDVERSION <= 0x5005005)
45044505450645074508450945104511451245134514#endif
/*
* Boilerplate macros
for
initializing and accessing interpreter-
local
* data from C. All statics in extensions should be reworked to
use
* this,
if
you want to make the extension thread-safe. See ext/re/re.xs
*
* Code that uses these macros is responsible
for
the following:
* 1.
#define MY_CXT_KEY to a unique string, e.g. "DynaLoader_guts"
* 2. Declare a typedef named my_cxt_t that is a structure that contains
45264527452845294530453145324533453445354536
defined
(PERL_CAPI) ||
defined
(PERL_IMPLICIT_CONTEXT)
#ifndef START_MY_CXT
/* This must appear in all extensions that define a my_cxt_t structure,
* right
after
the definition (i.e. at file scope). The non-threads
* case below uses it to declare the data as static. */
#define START_MY_CXT
#if (PERL_BCDVERSION < 0x5004068)
/* Fetches the SV that keeps the per-interpreter data. */
view all matches for this distribution
60566057605860596060606160626063606460656066#else
/* older perls don't have PL_numeric_radix_sv so the radix
* must manually be requested from locale.h
*/
#include <locale.h>
dTHR; /* needed
for
older threaded perls */
struct lconv
*lc
= localeconv();
char
*radix
=
lc
->decimal_point;
if
(radix && IN_LOCALE) {
STRLEN len = strlen(radix);
if
(
*sp
+ len <=
send
&& memEQ(
*sp
, radix, len)) {
view release on metacpan or search on metacpan
examples/bash/githubcl.bash view on Meta::CPAN
3536373839404142434445__githubcl_handle_options_flags
case
$INDEX
in
1)
__comp_current_options ||
return
__githubcl_dynamic_comp
'commands'
'/gists/:id'
$
'\t'
'Delete a gist.'
$
'\n'
'/gists/:id/comments/:commentId'
$
'\t'
'Delete a comment.'
$
'\n'
'/gists/:id/star'
$
'\t'
'Unstar a gist.'
$
'\n'
'/notifications/threads/:id/subscription'
$
'\t'
'Delete a Threa...
;;
*)
# subcmds
case ${MYWORDS[1]} in
examples/bash/githubcl.bash view on Meta::CPAN
9899100101102103104105106107108
esac
;;
esac
;;
/notifications/threads/:id/subscription)
FLAGS+=()
OPTIONS+=()
__githubcl_handle_options_flags
case
$INDEX
in
2)
examples/bash/githubcl.bash view on Meta::CPAN
744745746747748749750751752753754__githubcl_handle_options_flags
case
$INDEX
in
1)
__comp_current_options ||
return
__githubcl_dynamic_comp
'commands'
'/emojis'
$
'\t'
'Lists all the emojis available to use on GitHub....'
$
'\n'
'/events'
$
'\t'
'List public events.'
$
'\n'
'/feeds'
$
'\t'
'List Feeds.'
$
'\n'
'/gists'
$
'\t'
'List the authenticated user'
"'"
's gists or
if
...
;;
*)
# subcmds
case ${MYWORDS[1]} in
examples/bash/githubcl.bash view on Meta::CPAN
11111112111311141115111611171118111911201121
esac
;;
esac
;;
/notifications/threads/:id)
FLAGS+=()
OPTIONS+=()
__githubcl_handle_options_flags
case
$INDEX
in
2)
examples/bash/githubcl.bash view on Meta::CPAN
11291130113111321133113411351136113711381139
esac
;;
esac
;;
/notifications/threads/:id/subscription)
FLAGS+=()
OPTIONS+=()
__githubcl_handle_options_flags
case
$INDEX
in
2)
examples/bash/githubcl.bash view on Meta::CPAN
38573858385938603861386238633864386538663867__githubcl_handle_options_flags
case
$INDEX
in
1)
__comp_current_options ||
return
__githubcl_dynamic_comp
'commands'
'/gists/:id'
$
'\t'
'Edit a gist.'
$
'\n'
'/gists/:id/comments/:commentId'
$
'\t'
'Edit a comment.'
$
'\n'
'/notifications/threads/:id'
$
'\t'
'Mark a thread as read'
$
'\n'
'/orgs/:org'
$
'\t'
'Edit an Organization.'
$
'\n'
'/...
;;
*)
# subcmds
case ${MYWORDS[1]} in
examples/bash/githubcl.bash view on Meta::CPAN
39023903390439053906390739083909391039113912
esac
;;
esac
;;
/notifications/threads/:id)
FLAGS+=()
OPTIONS+=()
__githubcl_handle_options_flags
case
$INDEX
in
2)
examples/bash/githubcl.bash view on Meta::CPAN
48704871487248734874487548764877487848794880__githubcl_handle_options_flags
case
$INDEX
in
1)
__comp_current_options ||
return
__githubcl_dynamic_comp
'commands'
'/gists/:id/star'
$
'\t'
'Star a gist.'
$
'\n'
'/notifications'
$
'\t'
'Mark as read.'
$
'\n'
'/notifications/threads/:id/subscription'
$
'\t'
'Set a Thread Subscription.'
$
'\n'
'/orgs/:org/public_members/:username'
$
'\t'
...
;;
*)
# subcmds
case ${MYWORDS[1]} in
examples/bash/githubcl.bash view on Meta::CPAN
49004901490249034904490549064907490849094910
FLAGS+=()
OPTIONS+=()
__githubcl_handle_options_flags
__comp_current_options true ||
return
# no subcmds, no params/opts
;;
/notifications/threads/:id/subscription)
FLAGS+=()
OPTIONS+=()
__githubcl_handle_options_flags
case
$INDEX
in
2)
examples/bash/githubcl.bash view on Meta::CPAN
53105311531253135314531553165317531853195320__githubcl_handle_options_flags
case
$INDEX
in
2)
__comp_current_options ||
return
__githubcl_dynamic_comp
'commands'
'/gists/:id'
$
'\n'
'/gists/:id/comments/:commentId'
$
'\n'
'/gists/:id/star'
$
'\n'
'/notifications/threads/:id/subscription'
$
'\n'
'/orgs/:org/members/:username'
$
'\n'
'/orgs/:org/public_members/:username'
$
'\n'
...
;;
*)
# subcmds
case ${MYWORDS[2]} in
examples/bash/githubcl.bash view on Meta::CPAN
53345335533653375338533953405341534253435344
FLAGS+=()
OPTIONS+=()
__githubcl_handle_options_flags
__comp_current_options true ||
return
# no subcmds, no params/opts
;;
/notifications/threads/:id/subscription)
FLAGS+=()
OPTIONS+=()
__githubcl_handle_options_flags
__comp_current_options true ||
return
# no subcmds, no params/opts
;;
examples/bash/githubcl.bash view on Meta::CPAN
55215522552355245525552655275528552955305531__githubcl_handle_options_flags
case
$INDEX
in
2)
__comp_current_options ||
return
__githubcl_dynamic_comp
'commands'
'/emojis'
$
'\n'
'/events'
$
'\n'
'/feeds'
$
'\n'
'/gists'
$
'\n'
'/gists/:id'
$
'\n'
'/gists/:id/comments'
$
'\n'
'/gists/:id/comments/:commentId'
$
'\n'
'/gists/:id/star'
$
'\n'
'/gists/public'
$
'\n'
'/gists/starred'
$
'\n'
'/...
;;
*)
# subcmds
case ${MYWORDS[2]} in
examples/bash/githubcl.bash view on Meta::CPAN
56475648564956505651565256535654565556565657565856595660566156625663
FLAGS+=()
OPTIONS+=()
__githubcl_handle_options_flags
__comp_current_options true ||
return
# no subcmds, no params/opts
;;
/notifications/threads/:id)
FLAGS+=()
OPTIONS+=()
__githubcl_handle_options_flags
__comp_current_options true ||
return
# no subcmds, no params/opts
;;
/notifications/threads/:id/subscription)
FLAGS+=()
OPTIONS+=()
__githubcl_handle_options_flags
__comp_current_options true ||
return
# no subcmds, no params/opts
;;
examples/bash/githubcl.bash view on Meta::CPAN
64166417641864196420642164226423642464256426__githubcl_handle_options_flags
case
$INDEX
in
2)
__comp_current_options ||
return
__githubcl_dynamic_comp
'commands'
'/gists/:id'
$
'\n'
'/gists/:id/comments/:commentId'
$
'\n'
'/notifications/threads/:id'
$
'\n'
'/orgs/:org'
$
'\n'
'/repos/:owner/:repo'
$
'\n'
'/repos/:owner/:repo/comments/:commentId'
$
'\n'
'/repos/:owner/:repo/gi...
;;
*)
# subcmds
case ${MYWORDS[2]} in
examples/bash/githubcl.bash view on Meta::CPAN
64346435643664376438643964406441644264436444
FLAGS+=()
OPTIONS+=()
__githubcl_handle_options_flags
__comp_current_options true ||
return
# no subcmds, no params/opts
;;
/notifications/threads/:id)
FLAGS+=()
OPTIONS+=()
__githubcl_handle_options_flags
__comp_current_options true ||
return
# no subcmds, no params/opts
;;
examples/bash/githubcl.bash view on Meta::CPAN
67546755675667576758675967606761676267636764__githubcl_handle_options_flags
case
$INDEX
in
2)
__comp_current_options ||
return
__githubcl_dynamic_comp
'commands'
'/gists/:id/star'
$
'\n'
'/notifications'
$
'\n'
'/notifications/threads/:id/subscription'
$
'\n'
'/orgs/:org/public_members/:username'
$
'\n'
'/repos/:owner/:repo/collaborators/:user'
$
'\n'
'/repos/:owner/:repo/c...
;;
*)
# subcmds
case ${MYWORDS[2]} in
examples/bash/githubcl.bash view on Meta::CPAN
view all matches for this distribution
67726773677467756776677767786779678067816782
FLAGS+=()
OPTIONS+=()
__githubcl_handle_options_flags
__comp_current_options true ||
return
# no subcmds, no params/opts
;;
/notifications/threads/:id/subscription)
FLAGS+=()
OPTIONS+=()
__githubcl_handle_options_flags
__comp_current_options true ||
return
# no subcmds, no params/opts
;;
view release on metacpan or search on metacpan
view all matches for this distribution
858859860861862863864865866$(NOECHO) $(ECHO)
' <REQUIRE NAME="HTTP::Status" VERSION="6.18" />'
>> API-INSEE-Sirene.ppd
$(NOECHO) $(ECHO)
' <REQUIRE NAME="JSON::" VERSION="2.9" />'
>> API-INSEE-Sirene.ppd
$(NOECHO) $(ECHO)
' <REQUIRE NAME="LWP::UserAgent" VERSION="6.15" />'
>> API-INSEE-Sirene.ppd
$(NOECHO) $(ECHO)
' <REQUIRE NAME="POSIX::" VERSION="1.65" />'
>> API-INSEE-Sirene.ppd
$(NOECHO) $(ECHO)
' <REQUIRE NAME="Switch::" VERSION="2.17" />'
>> API-INSEE-Sirene.ppd
$(NOECHO) $(ECHO)
' <ARCHITECTURE NAME="x86_64-linux-gnu-thread-multi-5.28" />'
>> API-INSEE-Sirene.ppd
$(NOECHO) $(ECHO)
' <CODEBASE HREF="" />'
>> API-INSEE-Sirene.ppd
$(NOECHO) $(ECHO)
' </IMPLEMENTATION>'
>> API-INSEE-Sirene.ppd
$(NOECHO) $(ECHO)
'</SOFTPKG>'
>> API-INSEE-Sirene.ppd
view release on metacpan or search on metacpan
view all matches for this distribution
340341342343344345346347348349Released: 08/09/2003 Version: 1.81
(JCM) memory/multithreaded issue
with
errhash fixed { steve.drew at hp.com }
(JCM) uninitialized variable issue fixed { steve.drew at hp.com }
(JCM) memory free'ing on win32 issues fixed { steve.drew at hp.com }
view release on metacpan or search on metacpan
lib/ASNMTAP/Asnmtap/Applications.pod view on Meta::CPAN
view all matches for this distribution
1840184118421843184418451846184718481849=item RESET SLAVE
Makes the slave forget its replication position in the master's binlogs. This statement is meant to be used for a clean start: it deletes the `master.info' and `relay-log.info' files, all the relay logs, and starts a new relay log.
Note: All relay logs are deleted, even if they had not been totally executed by the slave SQL thread. (This is a condition likely to exist on a replication slave that is highly loaded, or if you have issued a STOP SLAVE statement.) Connection informa...
=item How do I configure a slave if the master is already running and I do not want to stop it?
There are several options. If you have taken a backup of the master at some point and recorded the binlog name and offset ( from the output of SHOW MASTER STATUS ) corresponding to the snapshot, do the following:
view release on metacpan or search on metacpan
view all matches for this distribution
4567891011121314/*
From http://blogs.perl.org/users/nick_wellnhofer/2015/03/writing-xs-like-a-pro---perl-
no
-get-context-and-static-functions.html
The perlxs man page recommends to define the PERL_NO_GET_CONTEXT macro
before
including EXTERN.h, perl.h, and XSUB.h.
If this macro is
defined
, it is assumed that the interpreter context is passed as a parameter to every function.
If it's undefined, the context will typically be fetched from thread-
local
storage
when
calling the Perl API, which
incurs a performance overhead.
WARNING:
setting this macro involves additional changes to the XS code. For example,
if
the XS file
has
static functions that