1
2
3
4
5
6
7
8
9#line 1 "Context.xs"
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31#include "EXTERN.h"
32#include "perl.h"
33#include "XSUB.h"
34#include "../../../perf.h"
35#include "../../../util/trace-event.h"
36
37#ifndef PERL_UNUSED_VAR
38# define PERL_UNUSED_VAR(var) if (0) var = var
39#endif
40
41#line 42 "Context.c"
42
43XS(XS_Perf__Trace__Context_common_pc);
44XS(XS_Perf__Trace__Context_common_pc)
45{
46#ifdef dVAR
47 dVAR; dXSARGS;
48#else
49 dXSARGS;
50#endif
51 if (items != 1)
52 Perl_croak(aTHX_ "Usage: %s(%s)", "Perf::Trace::Context::common_pc", "context");
53 PERL_UNUSED_VAR(cv);
54 {
55 struct scripting_context * context = INT2PTR(struct scripting_context *,SvIV(ST(0)));
56 int RETVAL;
57 dXSTARG;
58
59 RETVAL = common_pc(context);
60 XSprePUSH; PUSHi((IV)RETVAL);
61 }
62 XSRETURN(1);
63}
64
65
66XS(XS_Perf__Trace__Context_common_flags);
67XS(XS_Perf__Trace__Context_common_flags)
68{
69#ifdef dVAR
70 dVAR; dXSARGS;
71#else
72 dXSARGS;
73#endif
74 if (items != 1)
75 Perl_croak(aTHX_ "Usage: %s(%s)", "Perf::Trace::Context::common_flags", "context");
76 PERL_UNUSED_VAR(cv);
77 {
78 struct scripting_context * context = INT2PTR(struct scripting_context *,SvIV(ST(0)));
79 int RETVAL;
80 dXSTARG;
81
82 RETVAL = common_flags(context);
83 XSprePUSH; PUSHi((IV)RETVAL);
84 }
85 XSRETURN(1);
86}
87
88
89XS(XS_Perf__Trace__Context_common_lock_depth);
90XS(XS_Perf__Trace__Context_common_lock_depth)
91{
92#ifdef dVAR
93 dVAR; dXSARGS;
94#else
95 dXSARGS;
96#endif
97 if (items != 1)
98 Perl_croak(aTHX_ "Usage: %s(%s)", "Perf::Trace::Context::common_lock_depth", "context");
99 PERL_UNUSED_VAR(cv);
100 {
101 struct scripting_context * context = INT2PTR(struct scripting_context *,SvIV(ST(0)));
102 int RETVAL;
103 dXSTARG;
104
105 RETVAL = common_lock_depth(context);
106 XSprePUSH; PUSHi((IV)RETVAL);
107 }
108 XSRETURN(1);
109}
110
111#ifdef __cplusplus
112extern "C"
113#endif
114XS(boot_Perf__Trace__Context);
115XS(boot_Perf__Trace__Context)
116{
117#ifdef dVAR
118 dVAR; dXSARGS;
119#else
120 dXSARGS;
121#endif
122 const char* file = __FILE__;
123
124 PERL_UNUSED_VAR(cv);
125 PERL_UNUSED_VAR(items);
126 XS_VERSION_BOOTCHECK ;
127
128 newXSproto("Perf::Trace::Context::common_pc", XS_Perf__Trace__Context_common_pc, file, "$");
129 newXSproto("Perf::Trace::Context::common_flags", XS_Perf__Trace__Context_common_flags, file, "$");
130 newXSproto("Perf::Trace::Context::common_lock_depth", XS_Perf__Trace__Context_common_lock_depth, file, "$");
131 if (PL_unitcheckav)
132 call_list(PL_scopestack_ix, PL_unitcheckav);
133 XSRETURN_YES;
134}
135
136