lib/cppAdaptive2.pm

filter: Statementstmt 81.2% 13 / 16 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 80.0% 4 / 5 Podpod 0.0% 0 / 2 totaltotal 73.9% 17 / 23 CC 1 SCAR 0.5
CC
1
Cov
81%
update
1.1
update
1.1
BEGIN
1.0
CRAP 1.1
↑ Summary blib/lib/cppAdaptive2/Inline.pm »
1 package cppAdaptive2 v3.0.3;
2  
3 2 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 2 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
5  
6 2 ▶use cppAdaptive2::Inline(
Subroutine BEGIN: called CC=1 SCAR=0.0
7 2 CPP => <<'CPP',
8 #undef seed
9 #undef do_open
10 #undef do_close
11 #undef open
12 #undef read
13 #undef write
14 #undef close
15 #undef bind
16 #undef seekdir
17 #undef setbuf
18 #undef wait
19 #undef PP
20  
21 #include "cppAdaptive.cpp"
22  
23 AV* _update( char* obsVector, char* futVector, char* betaVector, int n_observed ) {
24 string obsVector1(obsVector);
25 string futVector1(futVector);
26 string betaVector1(betaVector);
27  
28 cppAdaptive( obsVector1, futVector1, betaVector1, n_observed );
29  
30 AV* av = newAV();
31 sv_2mortal((SV*)av);
32  
33 av_push( av, newSVpv(betaVector1.c_str(), betaVector1.size()) );
34 av_push( av, newSVpv(futVector1.c_str(), futVector1.size()) );
35  
36 return av;
37 }
38 CPP
39  
40 # without omp
41 # inc => '-I../../../../src',
42 # ccflags => '-std=c++11',
43  
44 # with omp
45 inc => '-I../../../../src',
46 ccflags => '-std=c++11 -fopenmp -O3',
47 lddlflags => '-shared -O3 -fstack-protector-strong -fopenmp',
48  
49 clean_after_build => 0,
50 clean_build_area => 0,
51 2 );
52  
53 1 ▶sub update {
Subroutine update: called CC=1 SCAR=1.2
Pod undocumented
54 0 ▶ my ( $obsVector, $futVector, $betaVector, $n_observed ) = @_;
Subroutine update: not called CC=1 SCAR=1.2
Pod undocumented
55  
56 0 return @{ _update( $obsVector, $futVector, $betaVector, $n_observed ) };
57 }
58  
59 2 1;
60 __END__
↑ Summary blib/lib/cppAdaptive2/Inline.pm »