KGRKJGETMRETU895U-589TY5MIGM5JGB5SDFESFREWTGR54TY
Server : Apache/2.2.17 (Unix) mod_ssl/2.2.17 OpenSSL/0.9.8e-fips-rhel5 DAV/2 PHP/5.2.17
System : Linux localhost 2.6.18-419.el5 #1 SMP Fri Feb 24 22:47:42 UTC 2017 x86_64
User : nobody ( 99)
PHP Version : 5.2.17
Disable Function : NONE
Directory :  /proc/21571/root/usr/lib64/python2.4/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : //proc/21571/root/usr/lib64/python2.4/profile.pyc
mņ
‚=5Dc	@sdZdkZdkZdkZdkZdklZddddgZedd„Z	ed	„Z
d
„Zeidjodk
Z
e
id„Zneed
ƒoeid„Zndfd„ƒYZd„Zedjo+dZeidodGeGHeidƒndefd„ƒYZeeƒZee_eidddddddeƒeidddd dd!ddƒeiƒ\ZZ e ei(e!eiƒd"joNei"i#d"ei"i$eid"ƒƒe	d#eid"fei%ei&ƒn
dGeGHndS($s Class for profiling Python code.N(sOptionParsertruntrunctxthelptProfilei’’’’cCsatƒ}y|i|ƒ}Wntj
onX|dj	o|i|ƒn|i|ƒSdS(sRun statement under profiler optionally saving results in filename

    This function takes a single argument that can be passed to the
    "exec" statement, and an optional file name.  In all cases this
    routine attempts to "exec" its first argument and gather profiling
    statistics from the execution. If no file name is present, then this
    function automatically prints a simple profiling report, sorted by the
    standard name string (file/line/function-name) that is presented in
    each line.
    N(
RtprofRt	statementt
SystemExittfilenametNonet
dump_statstprint_statstsort(RRRR((t/usr/lib64/python2.4/profile.pyR;s
	
cCsdtƒ}y|i|||ƒ}Wntj
onX|dj	o|i	|ƒn|i
ƒSdS(s·Run statement under profiler, supplying your own globals and locals,
    optionally saving results in filename.

    statement and filename have the same semantics as profile.run
    N(RRRRtglobalstlocalsRRRR	R
(RR
RRR((RRPs	
cCsuxntiD]Z}tii|dƒ}tii|ƒo,tid|ƒ}|o
dG|GHnPq
q
WdGdGHdS(Nsprofile.docs${PAGER-more} s*** Pager exit status:s-Sorry, can't find the help file "profile.doc"salong the Python search path.(	tsystpathtdirnametostjointfullnametexiststsystemtsts(RRR((RRbs

	tmaccCs|ƒdS(Nf60.0(ttimer(R((Rt
_get_time_macpsttimescCs|ƒ}|d|dS(Nii(Rtt(RR((Rt_get_time_timests	cBs?tZdZdZeed„Zd„Zd„Zd„Zd„Z	d„Z
d„Zd	„Zd
„Z
hde<de
<d
e
<de<de
<de
<Zd„Zdfd„ƒYZdfd„ƒYZd„Zd„Zdd„Zd„Zd„Zd„Zd„Zd„Zd„Zdd „Zd!„ZRS("sProfiler class.

    self.cur is always a tuple.  Each such tuple corresponds to a stack
    frame that is currently active (self.cur[-2]).  The following are the
    definitions of its members.  We use this external "parallel stack" to
    avoid contaminating the program that we are profiling. (old profiler
    used to write into the frames local dictionary!!) Derived classes
    can change the definition of some entries, as long as they leave
    [-2:] intact (frame and previous tuple).  In case an internal error is
    detected, the -3 element is used as the function name.

    [ 0] = Time that needs to be charged to the parent frame's function.
           It is used so that a function call will not have to access the
           timing data for the parent frame.
    [ 1] = Total time spent in this frame's function, excluding time in
           subfunctions (this latter is tallied in cur[2]).
    [ 2] = Total time spent in subfunctions, excluding time executing the
           frame's function (this latter is tallied in cur[1]).
    [-3] = Name of the function that corresponds to this frame.
    [-2] = Actual frame that we correspond to (used to sync exception handling).
    [-1] = Our parent 6-tuple (corresponds to frame.f_back).

    Timing data for each function is stored as a 5-tuple in the dictionary
    self.timings[].  The index is always the name stored in self.cur[-3].
    The following are the definitions of the members:

    [0] = The number of times this function was called, not counting direct
          or indirect recursion,
    [1] = Number of times this function appears on the stack, minus one
    [2] = Total time spent internal to this function
    [3] = Cumulative time that this function was present on the stack.  In
          non-recursive functions, this is the total execution time from start
          to finish of each invocation of a function, including time spent in
          all subfunctions.
    [4] = A dictionary indicating for each function name, the number of times
          it was called by us.
    icCsÅh|_d|_d|_d|_|djo
|i}n||_|djoĄti	djo%t
i|_|i|_
t|_q„ttdƒo#ti|_|_|i|_
q„ttdƒo%ti|_|i|_
t|_q„ti|_|_|i|_
n’||_|iƒ}yt|ƒ}Wn(tj
o||_|i|_
nCX|djo|i|_
n
|i|_
|td„}||_|iƒ|_|idƒdS(NtRtclockRicCs
||ƒƒS(N(tsumR(RR ((Rtget_time_timerĶstprofiler(tselfttimingsRtcurtcmdtc_func_nametbiasRRtnametMacOStGetTicksttrace_dispatch_mact
dispatcherRtget_timethasattrttimeRttrace_dispatch_iRttrace_dispatchRRtlentlengtht	TypeErrorttrace_dispatch_lR R!t
simulate_call(R#RR(R!R4R((Rt__init__¢sF				

	


		
	cCs±|i}|ƒ}|d|d|i|i}|djo|i|_n|i||||ƒo"|ƒ}|d|d|_n#|ƒ}|d|d||_dS(Niitc_call(R#RRR(teventtargt__name__R'tdispatchtframetr(R#R>R:R;RR?R((RR2Õs		 
		cCs{|i}|ƒ|i|i}|djo|i|_n|i||||ƒo|ƒ|_n|ƒ||_dS(NR9(
R#RRR(R:R;R<R'R=R>(R#R>R:R;RR((RR1ēs	
cCs‡|i}|ƒd|i|i}|djo|i|_n|i||||ƒo|ƒd|_n|ƒd||_dS(Nf60.0R9(
R#RRR(R:R;R<R'R=R>(R#R>R:R;RR((RR,ös	
cCs{|i}|ƒ|i|i}|djo|i|_n|i||||ƒo|ƒ|_n|ƒ||_dS(NR9(
R#R.RR(R:R;R<R'R=R>(R#R>R:R;RR.((RR6s	
c	Csf|i\}}}}}}||j	o|o|i	||ƒSn|||||||f|_dS(Ni(R#R%trpttrittrettrfntrframetrcurR>ttrace_dispatch_returnR(	R#R>RR@RERDRBRCRA((Rttrace_dispatch_exceptions
cCs†|ioŠ|i|idj	o¹|i\}}}}}}t
|tiƒp‡|i|ijp"t
d|||i||if‚|i|dƒ|idjp.|i|idjpt
d|idf‚qŚn|i}	|	i|	i|	if}|dd|||if|_|i}
||
jo:|
|\}
}}}}|
|d|||f|
|<nddddhf|
|<dS(Niž’’’sBad calliiż’’’i(R#R%R>tf_backR@RARBRCRDREt
isinstanceRt
fake_frametAssertionErrorRFRtf_codetfcodetco_filenametco_firstlinenotco_nametfnRR$tcctnsttttcttcallers(R#R>RRSR@RERDRBRCRMR$RVRTRRRQRARU((Rttrace_dispatch_calls!5F		
!c
Cs dd|if}|dd|||if|_|i}|i|ƒo:||\}}}}	}||d||	|f||<nddddhf||<dS(NRii(
R#R'RQRR>R%R$thas_keyRRRSRTRURV(
R#R>RRRR$RVRTRSRQRU((Rttrace_dispatch_c_call5s	!cCsZ||idj	oI||idijptd|idf‚|i|iddƒn|i\}}}}	}}||}||}|\}}}}}}||||||||f|_|i}
|
|	\}}}
}}|p||}|d}n||jo||d||<nd||<||d|
|||f|
|	<dS(Niž’’’s
Bad returniż’’’ii(R>R#R%RHRKRFR@RARBRCRERtframe_totaltppttpittpettpfntpframetpcurR$RRRSRTRURV(R#R>RRVRZR@RERSRBRCR$R]R`RTRRR[R_R^R\RARU((RRF@s$.

#	


!tcallt	exceptiontreturnR9tc_exceptiontc_returncCs0|idodSn||_|i|ƒdS(Ni’’’’(R#R%R&R7(R#R&((Rtset_cmdvs	t	fake_codecBstZd„Zd„ZRS(NcCs(||_||_||_d|_dS(Ni(RR#RNtlinetco_lineR)RPRO(R#RRhR)((RR8|s			cCst|i|i|ifƒS(N(treprR#RNRiRP(R#((Rt__repr__‚s(R<t
__module__R8Rk(((RRg{s	RJcBstZd„ZRS(NcCs||_||_dS(N(tcodeR#RLtpriorRH(R#RmRn((RR8†s	(R<RlR8(((RRJ…scCsc|idd|ƒ}|io|id}nd}|i||ƒ}|i	d||dƒdS(Ntprofileiiž’’’Ra(
R#RgR)RmR%R_RRJR>R=(R#R)RmR_R>((RR7Šs
cCsg|i}|ƒ|i}x7|ido(|id||id|ƒd}qW|ƒ||_dS(Ni’’’’Rciž’’’i(R#R.RR%R=(R#R.R((Rtsimulate_cmd_complete–s	i’’’’cCs/dk}|i|ƒiƒi|ƒiƒdS(N(tpstatstStatsR#t
strip_dirst
sort_statsRR
(R#RRq((RR
”s	cCs:t|dƒ}|iƒti|i|ƒ|iƒdS(Ntwb(	topentfiletfR#tcreate_statstmarshaltdumptstatstclose(R#RwRx((RR	¦s
cCs|iƒ|iƒdS(N(R#Rptsnapshot_stats(R#((RRy¬s
c	Cs‹h|_x{|iiƒD]j\}\}}}}}|i
ƒ}d}x|iƒD]}||7}qSW|||||f|i|<qWdS(Ni(R#R|R$t	iteritemstfuncRRRSRTRURVtcopytnct
itervaluestcallcnt(	R#R„RRR‚RVR€RSRTRU((RR~°s	
cCs%dk}|i}|i|||ƒS(N(t__main__t__dict__tdictR#RR&(R#R&R‡R…((RR½s		cBs@|i|ƒei|iƒz|||UWdeidƒX|S(N(	R#RfR&Rt
setprofileR-R
RR(R#R&R
R((RRĀs
cOsI|it|ƒƒti|iƒz|||ŽSWdtidƒXdS(N(
R#RfRjR€RRˆR-targstkwR(R#R€R‰RŠ((RtruncallĢscCsW|itj	otdƒ‚n|i}d|_z|i||ƒSWd||_XdS(Ns&Subclasses must override .calibrate().i(	R#t	__class__RR5R(t
saved_biast_calibrate_innertmtverbose(R#RRR((Rt	calibrateżs		cCs‰|i}d„}|d„}||ƒ|ƒ}||ƒ|ƒ}||}	|o
dG|	GHnt	ƒ}|ƒ}|idtƒt
ƒƒ|ƒ}||}
|o
dG|
GHnd}d}xZ|iiƒD]I\\}}
}\}}}}}|djo||7}||7}qŠqŠW|od	G|GHd
G|GHn||djotd|ƒ‚n||	d
|}|o
dG|GHn|S(NcCs!xt|ƒD]}d}q
WdS(Ni(trangetntitx(R“R”R•((Rtf1s
cCs%xt|ƒD]}|dƒq
WdS(Nid(R’RR”R–(RR–R”((RRxs
s elapsed time without profiling =sf(m)selapsed time with profiling =f0.0RxR–s!'CPU seconds' profiler reported =stotal # calls =is internal error: total calls = %df2.0s+mean stopwatch overhead per profile event =(Rxsf1(R#R.R–RxRtt0tt1telapsed_noprofileRRtpRR
Rtelapsed_profilettotal_callst
reported_timeR$titemsRRhtfuncnameRRRSRTRURVt
ValueErrortmean(R#RRR–RRR˜RURRSR™R›RRœRhRxR—RŸRšRVR.RTR”((RRŽsB		
	
	

			

$

	

(R<Rlt__doc__R(RR8R2R1R,R6RGRWRYRFR=RfRgRJR7RpR
R	RyR~RRR‹R‘RŽ(((RRys4%3								&<	
					
		
	1cGs	dGHdS(Ns7Report generating functions are in the "pstats" module((R‰((RRrGsR…s?profile.py [-o output_file_path] [-s sort] scriptfile [arg] ...isUsage: it
ProfileParsercBstZd„ZRS(NcCsti|ƒ||_dS(N(tOptionParserR8R#tusage(R#R„((RR8Ss
(R<RlR8(((RR£Rss-os	--outfiletdesttoutfilesSave stats to <outfile>tdefaults-ss--sortRs?Sort order when printing to stdout, based on pstats.Stats classisexecfile(%r)('R¢RRR0RztoptparseR¤t__all__RRRRR)R*R+RR/RRRRrR<R„targvtexitR£tparsertFalsetallow_interspersed_argst
add_optiont
parse_argstoptionsR‰R3RtinsertRR§R(R*R£RrRR­RRŖRR„RR¤RR‰RRRzR0RR²((Rt?
sF				
		’Ļ	
		
&(

Anon7 - 2021