HEX

Warning: set_time_limit() [function.set-time-limit]: Cannot set time limit - prohibited by configuration in /home/u547966/brikov.ru/www/wp-content/plugins/admin-menu-editor/menu-editor.php on line 745
Server: Apache
System: Linux 4.19.0-0.bpo.9-amd64 x86_64 at red40
User: u547966 (5490)
PHP: 5.3.29-mh2
Disabled: syslog, dl, popen, proc_open, proc_nice, proc_get_status, proc_close, proc_terminate, posix_mkfifo, chown, chgrp, accelerator_reset, opcache_reset, accelerator_get_status, opcache_get_status, pcntl_alarm, pcntl_fork, pcntl_waitpid, pcntl_wait, pcntl_wifexited, pcntl_wifstopped, pcntl_wifsignaled, pcntl_wifcontinued, pcntl_wexitstatus, pcntl_wtermsig, pcntl_wstopsig, pcntl_signal, pcntl_signal_dispatch, pcntl_get_last_error, pcntl_strerror, pcntl_sigprocmask, pcntl_sigwaitinfo, pcntl_sigtimedwait, pcntl_exec, pcntl_getpriority, pcntl_setpriority
Upload Files
File: //usr/lib/python3.5/__pycache__/tracemalloc.cpython-35.pyc


Fa=@s`ddlmZmZddlmZddlZddlZddlZddl	Z	ddl
Tddl
mZmZddZ
Gdd	d	ZGd
ddZdd
ZeGdddZeGdddeZddZGdddZGdddeZddZGdddZGdddZddZdS) )SequenceIterable)total_orderingN)*)_get_object_traceback_get_tracescCsxd
D]}t|dkrM|dkrM|r?d||fSd||fSt|dksk|dkr|rd||fSd||fS|d
}qWdS)NBKiBMiBGiBTiBdz%+.1f %sz%.1f %s
iz%+.0f %sz%.0f %s)rr	r
rri()abs)sizeZsignZunitr!/usr/lib/python3.5/tracemalloc.py_format_size
s
rc@sdeZdZdZdZddZddZd	d
ZddZd
dZ	ddZ
dS)	StatisticzS
    Statistic difference on memory allocations between two Snapshot instance.
    	tracebackrcountcCs||_||_||_dS)N)rrr)selfrrrrrr__init__%s		zStatistic.__init__cCst|j|j|jfS)N)hashrrr)rrrr__hash__*szStatistic.__hash__cCs4|j|jko3|j|jko3|j|jkS)N)rrr)rotherrrr__eq__-szStatistic.__eq__cCsYd|jt|jd|jf}|jrU|j|j}|dt|d7}|S)Nz%s: size=%s, count=%iFz, average=%s)rrrr)rtextaveragerrr__str__2s
	zStatistic.__str__cCsd|j|j|jfS)Nz)<Statistic traceback=%r size=%i count=%i>)rrr)rrrr__repr__<szStatistic.__repr__cCs|j|j|jfS)N)rrr)rrrr	_sort_key@szStatistic._sort_keyN)rrr)__name__
__module____qualname____doc__	__slots__rrrrr r!rrrrrs
rc@sdeZdZdZdZddZd	d
ZddZd
dZddZ	ddZ
dS)
StatisticDiffzd
    Statistic difference on memory allocations between an old and a new
    Snapshot instance.
    rr	size_diffr
count_diffcCs1||_||_||_||_||_dS)N)rrr(rr))rrrr(rr)rrrrKs
				zStatisticDiff.__init__cCs(t|j|j|j|j|jfS)N)rrrr(rr))rrrrrRszStatisticDiff.__hash__cCsX|j|jkoW|j|jkoW|j|jkoW|j|jkoW|j|jkS)N)rrr(rr))rrrrrrVs
zStatisticDiff.__eq__cCsnd|jt|jdt|jd|j|jf}|jrj|j|j}|dt|d7}|S)Nz %s: size=%s (%s), count=%i (%+i)FTz, average=%s)rrrr(rr))rrrrrrr]s
	zStatisticDiff.__str__cCs&d|j|j|j|j|jfS)Nz9<StatisticDiff traceback=%r size=%i (%+i) count=%i (%+i)>)rrr(rr))rrrrr iszStatisticDiff.__repr__cCs.t|j|jt|j|j|jfS)N)rr(rr)rr)rrrrr!nszStatisticDiff._sort_keyN)rrr(rr))r"r#r$r%r&rrrrr r!rrrrr'Dsr'cCsg}x|jD]\}}|j|d}|dk	rrt||j|j|j|j|j|j}n$t||j|j|j|j}|j|qWxG|jD]9\}}t|d|jd|j}|j|qW|S)Nr)itemspopr'rrappend)	old_group	new_group
statisticsrstatZpreviousrrr_compare_grouped_statsts r1c@seZdZdZdZddZeddZeddZd	d
Z	ddZ
d
dZddZddZ
dS)Framez
    Frame of a traceback.
    _framecCs
||_dS)N)r3)rframerrrrszFrame.__init__cCs|jdS)Nr)r3)rrrrfilenameszFrame.filenamecCs|jdS)N)r3)rrrrlinenoszFrame.linenocCs|j|jkS)N)r3)rrrrrrszFrame.__eq__cCs|j|jkS)N)r3)rrrrr__lt__szFrame.__lt__cCs
t|jS)N)rr3)rrrrrszFrame.__hash__cCsd|j|jfS)Nz%s:%s)r5r7)rrrrrsz
Frame.__str__cCsd|j|jfS)Nz<Frame filename=%r lineno=%r>)r5r7)rrrrr szFrame.__repr__N)r3)r"r#r$r%r&rpropertyr5r7rr8rrr rrrrr2sr2c@seZdZdZdZddZddZddZd	d
ZddZ	d
dZ
ddZddZddZ
dddZdS)	Tracebackz`
    Sequence of Frame instances sorted from the most recent frame
    to the oldest frame.
    _framescCstj|||_dS)N)rrr;)rframesrrrrs
zTraceback.__init__cCs
t|jS)N)lenr;)rrrr__len__szTraceback.__len__cCsBt|tr-tdd|j|DSt|j|SdS)Ncss|]}t|VqdS)N)r2).0tracerrr	<genexpr>sz(Traceback.__getitem__.<locals>.<genexpr>)
isinstanceslicetupler;r2)rindexrrr__getitem__szTraceback.__getitem__cCs|j|jkS)N)r3r;)rr4rrr__contains__szTraceback.__contains__cCs
t|jS)N)rr;)rrrrrszTraceback.__hash__cCs|j|jkS)N)r;)rrrrrrszTraceback.__eq__cCs|j|jkS)N)r;)rrrrrr8szTraceback.__lt__cCst|dS)Nr)str)rrrrrszTraceback.__str__cCsdt|fS)Nz<Traceback %r>)rD)rrrrr szTraceback.__repr__NcCsg}|dk	r"|dkr"|Sxj|d|D]X}|jd|j|jftj|j|jj}|r3|jd|q3W|S)Nrz  File "%s", line %sz    %s)r,r5r7	linecachegetlinestrip)rlimitlinesr4linerrrformats	zTraceback.format)r;)r"r#r$r%r&rr>rFrGrrr8rr rOrrrrr:sr:cCs*t|}|dk	r"t|SdSdS)z
    Get the traceback where the Python object *obj* was allocated.
    Return a Traceback instance.

    Return None if the tracemalloc module is not tracing memory allocations or
    did not trace the allocation of the object.
    N)rr:)objr<rrrget_object_tracebacks
rQc@s|eZdZdZdZddZeddZeddZd	d
Z	ddZ
d
dZddZdS)Tracez"
    Trace of a memory block.
    _tracecCs
||_dS)N)rS)rr@rrrrszTrace.__init__cCs|jdS)Nr)rS)rrrrrsz
Trace.sizecCst|jdS)Nr6)r:rS)rrrrrszTrace.tracebackcCs|j|jkS)N)rS)rrrrrrszTrace.__eq__cCs
t|jS)N)rrS)rrrrrszTrace.__hash__cCsd|jt|jdfS)Nz%s: %sF)rrr)rrrrr	sz
Trace.__str__cCsdt|jd|jfS)Nz<Trace size=%s, traceback=%r>F)rrr)rrrrr szTrace.__repr__N)rS)
r"r#r$r%r&rr9rrrrrr rrrrrRsrRc@sXeZdZddZddZddZddZd	d
ZddZd
S)_TracescCstj|||_dS)N)rr_traces)rtracesrrrrs
z_Traces.__init__cCs
t|jS)N)r=rU)rrrrr>sz_Traces.__len__cCsBt|tr-tdd|j|DSt|j|SdS)Ncss|]}t|VqdS)N)rR)r?r@rrrrAsz&_Traces.__getitem__.<locals>.<genexpr>)rBrCrDrUrR)rrErrrrFsz_Traces.__getitem__cCs|j|jkS)N)rSrU)rr@rrrrG sz_Traces.__contains__cCs|j|jkS)N)rU)rrrrrr#sz_Traces.__eq__cCsdt|S)Nz<Traces len=%s>)r=)rrrrr &sz_Traces.__repr__N)	r"r#r$rr>rFrGrr rrrrrTsrTcCs5tjj|}|jdr1|dd}|S)Nz.pycr6)ospathnormcaseendswith)r5rrr_normalize_filename*sr\c@sXeZdZddddZeddZddZd	d
ZddZdS)
FilterNFcCs.||_t||_||_||_dS)N)	inclusiver\_filename_patternr7
all_frames)rr^filename_patternr7r`rrrr2s		zFilter.__init__cCs|jS)N)r_)rrrrra9szFilter.filename_patterncCsIt|}tj||js%dS|jdkr8dS||jkSdS)NFT)r\fnmatchr_r7)rr5r7rrrZ
__match_frame=szFilter.__match_framecCs|j|||jAS)N)_Filter__match_framer^)rr5r7rrr_match_frameFszFilter._match_framecs^jr:tfdd|Dr/jSjSn |d\}}j||SdS)Nc3s'|]\}}j||VqdS)N)rc)r?r5r7)rrrrAKsz*Filter._match_traceback.<locals>.<genexpr>r)r`anyr^rd)rrr5r7r)rr_match_tracebackIs	
zFilter._match_traceback)	r"r#r$rr9rarcrdrfrrrrr]1s
	r]c@seZdZdZddZddZeddZdd	Zd
dZ	dd
Z
dddZdddZdS)SnapshotzB
    Snapshot of traces of memory blocks allocated by Python.
    cCst||_||_dS)N)rTrVtraceback_limit)rrVrhrrrrZszSnapshot.__init__cCs3t|d}tj||tjWdQRXdS)z1
        Write the snapshot into a file.
        wbN)openpickledumpZHIGHEST_PROTOCOL)rr5fprrrrl`sz
Snapshot.dumpc	Cs*t|d}tj|SWdQRXdS)z.
        Load a snapshot from a file.
        rbN)rjrkload)r5rmrrrrogsz
Snapshot.loadcs`|d|r3tfdd|Ds3dS|r\tfdd|Dr\dSdS)Nr6c3s|]}|jVqdS)N)rf)r?trace_filter)rrrrArsz)Snapshot._filter_trace.<locals>.<genexpr>Fc3s|]}|jVqdS)N)rf)r?rp)rrrrAvsT)re)rinclude_filtersexclude_filtersr@r)rr
_filter_traceos


zSnapshot._filter_tracecst|ts(tdt|j|rggx4|D],}|jr`j|qAj|qAWfddjjD}njjj	}t
|jS)z
        Create a new Snapshot instance with a filtered traces sequence, filters
        is a list of Filter instances.  If filters is an empty list, return a
        new Snapshot instance with a copy of the traces.
        z)filters must be a list of filters, not %scs+g|]!}j|r|qSr)rs)r?r@)rrrqrrr
<listcomp>s		z*Snapshot.filter_traces.<locals>.<listcomp>)rBr	TypeErrortyper"r^r,rVrUcopyrgrh)rfiltersrpZ
new_tracesr)rrrqrr
filter_traces{s
	(zSnapshot.filter_tracescCsG|dkrtd|f|rA|d	krAtd|i}i}|sTx|jjD]}|\}}y||}Wnstk
r|dkr|}	n6|dkr|dd}	n|dddff}	t|	}|||<YnXy,||}
|
j|7_|
jd7_Wq`tk
rLt||d||<Yq`Xq`Wnx|jjD]}|\}}x|D]}y||}WnStk
r|dkr|f}	n|ddff}	t|	}|||<YnXy,||}
|
j|7_|
jd7_Wqztk
r:t||d||<YqzXqzWqaW|S)
Nrr5r7zunknown key_type: %rz/cumulative mode cannot by used with key type %rr6r)rr5r7)r7r5)
ValueErrorrVrUKeyErrorr:rrr)rkey_type
cumulativeZstatsZ
tracebacksr@rZtrace_tracebackrr<r0r4rrr	_group_bysX

	

"



#zSnapshot._group_byFcCsA|j||}t|j}|jdddtj|S)zd
        Group statistics by key_type. Return a sorted list of Statistic
        instances.
        reverseTkey)r~listvaluessortrr!)rr|r}Zgroupedr/rrrr/szSnapshot.statisticscCsP|j||}|j||}t||}|jdddtj|S)z
        Compute the differences with an old snapshot old_snapshot. Get
        statistics as a sorted list of StatisticDiff instances, grouped by
        group_by.
        rTr)r~r1rr'r!)rZold_snapshotr|r}r.r-r/rrr
compare_tos
zSnapshot.compare_toN)
r"r#r$r%rrlstaticmethodrorsryr~r/rrrrrrgUs3
rgcCs4tstdt}t}t||S)zI
    Take a snapshot of traces of memory blocks allocated by Python.
    zLthe tracemalloc module must be tracing memory allocations to take a snapshot)Z
is_tracingRuntimeErrorrZget_traceback_limitrg)rVrhrrr
take_snapshots
			r)collectionsrr	functoolsrrbrIos.pathrXrkZ_tracemallocrrrrr'r1r2r:rQrRrTr\r]rgrrrrr<module>s*
&0#5!$