add-determinism 0.7.3

RPM buildroot helper to strip nondeterministic bits in files
Documentation
�

Jz`f�cs��SrSSKrSSKrSSKrSSKrSSK7 SSKJrJrJ	r	J
r
JrJrJ
r
Jr SSKJr /SQ\-rC\R"\R$\R&\\\4r\Sr\SrS	r\S
r\Sr\Sr\S
r\Sr \Sr!\Sr"\Sr#\Sr$\Sr%\Sr&\Sr'\Sr(\Sr)\Sr*\Sr+\,"\-5r.\/"\5r0\Rb"5Hur2r3\2\.\3'\3\0\2'M \
Rb"5VVVs0sHupUHo"U_M M snnnr4Sr5SuSSSSSS.Sjjr6SuSSSSS.Sjjr7S S!S"S#S$S%S&S'S(S)S*.
r8S+r9"S,S-5r:\:"5r;S.r<S/r=S0r>S1r?S2r@SS3.S4jrA\R�"S5/S6QS/S7-S89rC\R�"S9/S:Q/S;QS89rDS<\DRZlS=\DR
lS>\DR�lS?\DR�lS@\DR�lSA\DR�lSB\DR�lSC\DR�lSD\DR�lSE\DR�lSF\DR�lSG\DR�l\R�"SHSI5rO"SJSK\O5rPSLrQSMrRSNrSSOrT"SPSQ\D5rU"SRSS5rV"STSU5rWSSSSV.SWjrXSXrYSYrZSZr[S[r\S\r]S]r^SvS^jr_SwSSSSS.S_jjr`SSSSSS.S`jraSxSbjrbScrcSdrdSySSaSSSSSe.SfjjreSwSgjrfShrg\`rhSiriSj\iSk-
-rjSlrkSmrlSnrmSornSpro"SqSr5rpSsrq\rSt:Xa\q"5 ggs snnnf)zz0Disassembler of Python byte code into mnemonics.�N)Z*)�__all__�
_cache_format�_inline_cache_entries�_nb_ops�_intrinsic_1_descs�_intrinsic_2_descs�_specializations�_specialized_opmap)�get_executor)�	code_info�dis�disassemble�distb�disco�findlinestarts�
findlabels�	show_code�get_instructions�Instruction�Bytecode�
CONVERT_VALUE�SET_FUNCTION_ATTRIBUTE)�defaultsZ
kwdefaultsZannotationsZclosure�ENTER_EXECUTOR�
LOAD_CONST�RETURN_CONST�LOAD_GLOBAL�	BINARY_OP�
JUMP_BACKWARD�FOR_ITER�SEND�	LOAD_ATTR�LOAD_SUPER_ATTR�CALL_INTRINSIC_1�CALL_INTRINSIC_2�LOAD_FAST_LOAD_FAST�STORE_FAST_LOAD_FAST�STORE_FAST_STORE_FAST�CACHEcsT�[XS5$![a Of=f[XS5$)z�Attempts to compile the given source, first as an expression and
then as a statement if the first approach fails.

Utility function to accept strings in functions that otherwise
expect code objects
Zeval�exec)�compileZSyntaxError)�source�name�  �/usr/lib64/python3.13/dis.py�_try_compiler.As3��
��v�V�,�,���
��
���6��(�(s��
�F��file�depth�show_caches�adaptive�show_offsetscsj�Uc[XUUS9 g[US5(aURn[US5(a
URnOY[US5(a
URnO;[US5(a
UR
nO[US5(aURn[US5(ah[URR55nUH>upx[U[5(dM[S	U-US
9 [X�X#XES9 [US
9 M@ g[US
5(a[XX#XES9 g[U[ ["45(a|[%U5n
S['[)['U
555-n[+UU(a*['[)[-['U5S-
S555OSUUS9n[/U
S9n
[1X
US9 g[U[(5(a[3XX#XES9 g[S[5U5R6-5e![an	[SX�S
9 Sn	A	GNSn	A	ff=f)aDisassemble classes, methods, functions, and other compiled objects.

With no argument, disassemble the last traceback.

Compiled objects currently include generator objects, async generator
objects, and coroutine objects, all of which store their code object
in a special attribute.
N�r0r2r3r4�__func__�__code__�gi_code�ag_code�cr_code�__dict__zDisassembly of %s:�r0r/zSorry:�co_code���'r)r0�offset_width�label_widthr2)�
labels_map)�arg_resolver�	formatter�(don't know how to disassemble %s objects)r
�hasattrr6r7r8r9r:�sortedr;�items�
isinstance�
_have_code�printr�	TypeError�_disassemble_recursiveZbytesZ	bytearray�_make_labels_map�len�str�	Formatter�max�ArgResolver�_disassemble_bytes�_disassemble_str�type�__name__)�xr0r1r2r3r4rIr+Zx1ZmsgrCrBrErD�              r-rrNs���	�y�
�4�8�'�	)���q�*���
�J�J���q�*���
�J�J��	��I�	�	�
�I�I��	��I�	�	�
�I�I��	��I�	�	�
�I�I���q�*����q�z�z�'�'�)�*���	!�H�D��"�j�)�)��*�T�1��=�4���U�V^�z��4� �	!�
��I�	�	��q�5�\d�	A�	�A��y�)�	*�	*�%�a�(�
��#�c�#�j�/�2�3�3���4�NZ�3�s�3�s�1�v��z�4�3H�/I�+J�`a�*5�*5�7�	�#�j�9���1�9�M�	�A�s�	�	���U�V^�z��B��Q��(�(�)�*�	*��#!�4��(�C�3�3��4�s�H�
H2�
H-�-H2r5c	st�Ucq[[S5(a[RRnO[RnUR(aURoR(aM[URRURXX4S9 g![
a
 [
S5Sef=f)z2Disassemble a traceback (default: last traceback).N�last_excz no last traceback to disassembler5)rG�sysr[Z
__traceback__Zlast_tracebackZAttributeError�RuntimeError�tb_nextr�tb_frame�f_code�tb_lasti)�tbr0r2r3r4�     r-r
r
�s���	�z�	M��s�J�'�'��\�\�/�/���'�'���j�j�r�z�z�"�j�j�j�����"�"�B�K�K�d�^f�C���	M��A�B��L�	M�s�/B �B � B7Z	OPTIMIZEDZ	NEWLOCALSZVARARGSZVARKEYWORDSZNESTEDZ	GENERATORZNOFREEZ	COROUTINEZITERABLE_COROUTINEZASYNC_GENERATOR)
�r?r>��� �@i�iic	s�/n[S5HNnSU-nX-(dMUR[RU[	U555 X-nU(aMN O UR[	U55 SRU5$)z+Return pretty representation of code flags.rgrd�, )�range�append�COMPILER_FLAG_NAMES�getZhex�join)Zflags�names�iZflag�    r-�pretty_flagsrr�sx���E�
�2�Y�!���!�t���<�<��L�L�,�0�0��s�4�y�A�B��M�E��5��
!�	���S��Z� ��9�9�U���cs�\rSrSrSrSrg)�_Unknowni�cs�g)Nz	<unknown>���self� r-�__repr__Z_Unknown.__repr__�s��rsruN)rX�
__module__�__qualname__�__firstlineno__ry�__static_attributes__rursr-rtrt�s��rsrtcs��[US5(aURn[US5(a
URnOY[US5(a
URnO;[US5(a
URnO[US5(aUR
n[
U[5(a[US5n[US5(aU$[S[U5R-5e)	zDHelper to handle methods, compiled or raw code objects, and strings.r6r7r8r9r:z
<disassembly>r=rF)rGr6r7r8r9r:rJrQr.rMrWrX�rYrxr-�_get_code_objectr�s����q�*���
�J�J���q�*���
�J�J��	��I�	�	�
�I�I��	��I�	�	�
�I�I��	��I�	�	�
�I�I���!�S�����O�,���q�)�����
�>���G�$�$�%�&�&rscsL�[UnU[;a[[U$U$�N)�_all_opname�deoptmap�
_all_opmap)�opr+r,r-�_deoptopr��s&���r�?�D�)-��)9�:�h�t�n�%�A�r�Arscs��U(a�URn/nSn[S[U5S5H�nX%X%S-pvU[:Xa4[	X5nU(a!UR5UR5pvSnURUR55 URUR55 M� U(dU$SRU5$UR$![
[4a SnN�f=f)NFrr?rdTrs)
Z_co_code_adaptiverjrPrr	Z
ValueErrorr]Z
get_opcodeZ	get_opargrkZto_bytesrnr=)	�cor3�codeZresZfoundrpr��argZex�	         r-�_get_code_arrayr��s�����#�#�������q�#�d�)�Q�'�
	'�A��g�t�a�C�y���^�#��%�b�,�B�� �m�m�o�r�|�|�~�� �E��J�J�r�{�{�}�%��J�J�s�|�|�~�&�
	'�!�t�3�c�h�h�s�m�3��z�z���#�L�1���B��s�C!�!C6�5C6cs*�[[U55$)z1Formatted details of methods, functions, or code.)�_format_code_inforr~rxr-r
r
�s���-�a�0�1�1rscsN�/nURSUR-5 URSUR-5 URSUR-5 URSUR-5 URSUR
-5 URSUR-5 URSUR-5 URS[UR5-5 UR(aAURS	5 [UR5HnURS
U-5 M UR(aAURS5 [UR5HnURSU-5 M UR(aAURS
5 [UR5HnURSU-5 M UR(aAURS5 [UR5HnURSU-5 M UR(aAURS5 [UR5HnURSU-5 M SR!U5$)NzName:              %szFilename:          %szArgument count:    %szPositional-only arguments: %szKw-only arguments: %szNumber of locals:  %szStack size:        %szFlags:             %sz
Constants:z%4d: %rzNames:z%4d: %szVariable names:zFree variables:zCell variables:Z
)rkZco_nameZco_filenameZco_argcountZco_posonlyargcountZco_kwonlyargcountZ
co_nlocalsZco_stacksizerrZco_flags�	co_consts�	enumerate�co_namesZco_varnamesZco_freevarsZco_cellvarsrn)r�ZlinesZi_cZi_nrqr-r�r��s����E�	�L�L�(�2�:�:�5�6�	�L�L�(�2�>�>�9�:�	�L�L�(�2�>�>�9�:�	�L�L�0�2�3H�3H�H�I�	�L�L�(�2�+?�+?�?�@�	�L�L�(�2�=�=�8�9�	�L�L�(�2�?�?�:�;�	�L�L�(�<����+D�D�E�	�|�|�
���\�"��R�\�\�*�	*�C��L�L��S��)�	*�	�{�{�
���X���R�[�[�)�	*�C��L�L��S��)�	*�	�~�~�
���&�'��R�^�^�,�	*�C��L�L��S��)�	*�	�~�~�
���&�'��R�^�^�,�	*�C��L�L��S��)�	*�	�~�~�
���&�'��R�^�^�,�	*�C��L�L��S��)�	*��9�9�U��rsr<cs*�[[U5US9 g)zuPrint details of methods, functions, or code to *file*.

If *file* is not provided, the output is printed on stdout.
r<N)rLr
)r�r0r,r-rrs��

�)�B�-�d�#rs�	Positions)�linenoZ
end_linenoZ
col_offsetZend_col_offsetr>)r�_Instruction)�opname�opcoder��argval�argrepr�offset�start_offset�starts_line�line_number�label�	positions�
cache_info)NNNz!Human readable name for operationzNumeric code for operationz6Numeric argument to operation (if any), otherwise Nonez4Resolved arg value (if known), otherwise same as argz0Human readable description of operation argumentz1Start index of operation within bytecode sequencez|Start index of operation within bytecode sequence, including extended args if present; otherwise equal to Instruction.offsetz9True if this opcode starts a source line, otherwise FalsezGsource line number associated with this opcode (if any), otherwise NonezFA label (int > 0) if this instruction is a jump target, otherwise NonezPdis.Positions object holding the span of source code covered by this instructionzGlist of (name, size, data), one for each cache entry of the instruction�_ExceptionTableEntryBasezstart end target depth lastics�\rSrSrSrg)�_ExceptionTableEntryiDruN)rXrzr{r|r}rursr-r�r�Ds��rsr�i�cs0�[R"US5$�Nr)rrm�r�rxr-�_get_cache_sizer�Js�� �$�$�V�Q�/�/rscs��[U5n[[U5nU[;a([	U5(aU*nUS-US--nUSU--
nU$U[
;aUS-nU$SnU$)zcGets the bytecode offset of the jump target if this is a jump instruction.

Otherwise return None.
r?N)r�r�r��hasjrel�_is_backward_jump�hasjabs)r�r�r��deop�caches�target�      r-�_get_jump_targetr�Ms���
�B�<�D�
�[��.�
/�F��w���T�"�"��$�C��!��c�!�e�#���!�f�*���
�M�	
����Q����M����Mrscs��\rSrSrSr\S5r\S5r\S5r\S5r	\S5r
\S5r\S	5rS
r
Srg)
ri_a�Details for a bytecode operation.

Defined fields:
  opname - human readable name for operation
  opcode - numeric code for operation
  arg - numeric argument to operation (if any), otherwise None
  argval - resolved arg value (if known), otherwise same as arg
  argrepr - human readable description of operation argument
  offset - start index of operation within bytecode sequence
  start_offset - start index of operation within bytecode sequence including extended args if present;
                 otherwise equal to Instruction.offset
  starts_line - True if this opcode starts a source line, otherwise False
  line_number - source line number associated with this opcode (if any), otherwise None
  label - A label if this instruction is a jump target, otherwise None
  positions - Optional dis.Positions object holding the span of source code
              covered by this instruction
  cache_info - information about the format and content of the instruction's cache
                 entries (if any)
cs�UR$)zAlias for Instruction.arg.)r�rvrxr-�opargZInstruction.opargts
���x�x�rsc�,�[UR5$)ziNumeric code for the base operation if operation is specialized.

Otherwise equal to Instruction.opcode.
)r�r�rvrxr-�
baseopcodeZInstruction.baseopcodeys������$�$rscs(�[UR$)zpHuman readable name for the base operation if operation is specialized.

Otherwise equal to Instruction.opname.
)r�r�rvrxr-�
baseopnameZInstruction.baseopname�s���d�o�o�&�&rscs �URS-$)z9Start index of the cache entries following the operation.r?)r�rvrxr-�cache_offsetZInstruction.cache_offset�s���{�{�Q��rscsZ�UR[[UR5S--$)z7End index of the cache entries following the operation.r?)r�r�r�r�rvrxr-�
end_offsetZInstruction.end_offset�s(��� � �?�;�t�{�{�3K�#L�Q�#N�N�NrscsX�[URURUR5$)zWBytecode index of the jump target if this is a jump operation.

Otherwise return None.
)r�r�r�r�rvrxr-�jump_targetZInstruction.jump_target�s�� ����T�X�X�t�{�{�C�Crscs�URSL$)z1True if other code jumps to here, otherwise FalseN)r�rvrxr-�is_jump_targetZInstruction.is_jump_target�s���z�z��%�%rscs��[R"5n[US9nURUS5 UR	5$)Nr<F)�io�StringIOrR�print_instruction�getvalue)rw�outputrE�   r-�__str__ZInstruction.__str__�s4��������6�*�	��#�#�D�%�0���� � rs)r�r�r�r�r�r�N)rXrzr{r|�__doc__Zpropertyr�r�r�r�r�r�r�r�r}rursr-rr_s����(�����%��%��'��'������O��O��D��D��&��&�!rsrcs8�\rSrSrSSjrS	SjrSrSrSrg)
rRi�Ncs@�XlX lX0lX@lX`lg)a-Create a Formatter

*file* where to write the output
*lineno_width* sets the width of the line number field (0 omits it)
*offset_width* sets the width of the instruction offset field
*label_width* sets the width of the label field
*show_caches* is a boolean indicating whether to display cache lines

N�r0�lineno_widthrArBr2)rwr0r�rArB�line_offsetr2�       r-�__init__ZFormatter.__init__�s!���	�(��(��&��&�rscs��URX5 UR(a�UR(a�URnURH�upEn[	U5HlnUS-
nUS:Xa*US[
R
U[R53nOSnUR[S[SSX�USSSUR5S5 Mn M� ggg)Nr?rz: �r'F)�print_instruction_liner2r�r�rjZintZ
from_bytesr\Z	byteorderrr'r�)	rw�instr�mark_as_currentr�r+�size�datarpr�r�r-r�ZFormatter.print_instruction�s����#�#�E�;����� 0� 0��\�\�F�$)�$4�$4�
� ��D��t���A��a�K�F��A�v�%)�F�"�S�^�^�D�#�-�-�-P�,Q�"R��"$���/�/�#�G�U�A�t�W�f�$)�4��u���H����
�!1�rscs4�URnURnURnUS:�=(a" UR=(a URS:�nU(a[URS9 /nU(amUR(aHURbSOSnX�-nURc[OURn	URX�-5 OURSU-5 URb'SURS3n
URU
S	U35 OURSU-5 US:�a+UR[UR5S	U3S
35 U(aURS5 OURS5 URURR[55 URb�[UR5n[!S[#UR5[-
5nUR[UR5R%[&U-
55 UR((a!URS
UR(-S-5 [SR+U5R-5URS9 g)z?Format instruction details for inclusion in disassembly output.rr<Nz%%%ddz%%%dsZ ZL�:Z>z  z-->z   Z(�))r�rArBr�r�rLr0r��
_NO_LINENOrkr��reprr�Zljust�
_OPNAME_WIDTHr�rSrPZrjust�_OPARG_WIDTHr�rnZrstrip)
rwr�r�r�rArBZnew_source_lineZfieldsZ
lineno_fmtr��lblr�Z
opname_excesss
             r-r�Z Formatter.print_instruction_line�s���(�(���(�(���&�&��'�!�+�,� �,�,�,� �<�<�!�+�	���t�y�y�!����� � �(-�(9�(9�(E�W�7�
�'�6�
�',�'8�'8�'@��e�FW�FW���
�
�j�1�2��
�
�c�L�0�1��;�;�"��e�k�k�]�!�$�C��M�M�S��;�-��0�2��M�M�#��+�,��!���M�M�T�%�,�,�/��,��/?�@��C�D���M�M�%� ��M�M�%� ��
�
�e�l�l�(�(��7�8��9�9� ��u�y�y�/�C� ��3�u�|�|�#4�}�#D�E�M��M�M�$�u�y�y�/�/�/��}�0L�M�N��}�}��
�
�c�E�M�M�1�C�7�8�
�c�h�h�v��%�%�'�d�i�i�8rsc
s
�URnU(ap[SUS9 UH_nUR(aSOSnURnURnUR
n[SUSUSUSURS	U3
US9 Ma gg)
NzExceptionTable:r<z lastir�z  Lz to Lz -> Lz [Z])r0rL�lasti�start_label�	end_label�target_labelr1)rw�exception_entriesr0Zentryr��start�endr��        r-�print_exception_tableZFormatter.print_exception_table�s����y�y����#�$�/�*�
^��$)�K�K��R���)�)���o�o���+�+����E�7�%��u�E�&���E�K�K�=��%��Q�X\�]�
^�rs)r2r0r�rArB)NrrrrF)F)	rXrzr{r|r�r�r�r�r}rursr-rRrR�s��NO�27�'�"�$19�f	^rsrRcs0�\rSrSrSSjrSrSrSrSrg)	rTiNcsH�XlX lX0lU=(d 0Ulgr��r�ro�varname_from_opargrC)rwr�ror�rCrcr-r�ZArgResolver.__init__s��"���
�"4��$�*���rscs��[U5nU[;aUS-$U[;a<[U5(aU*OUnUS-US--n[	[
U5nUSU--
nU$g�Nr?)r�r�r�r�r�r�)rwr�r�r�r�Z
signed_argr�r�r�r-�offset_from_jump_argZ ArgResolver.offset_from_jump_argsl����|���7�?���7�N�
�W�_�!2�4�!8�!8�#��c�J��a�Z�*�Q�,�.�F�$�[��%6�7�F��a�&�j� �F��M�rscs:�URRUS5$r�)rCrm)rwr�r,r-�get_label_for_offsetZ ArgResolver.get_label_for_offsets�����"�"�6�4�0�0rscs^^�URcSOURRnSnSn[U5nTGbrTnU[;a[	UTUR
5upVXV4$U[;a�U[:Xa*[TS-U5upVTS-(aU(aUS3nXV4$U[:Xa*[TS-U5upVTS-(aU(aUS3nXV4$U[:Xa*[TS-U5upVTS-(aU(aUS3nXV4$[TU5upVXV4$U[;d
U[;a,URUTU5nURU5nSU3nXV4$U[[ ["4;aFTS-	n	TS-n
[X�R$5up�[X�R$5up�US	-U-nX�4nXV4$U[&;d
U[(;a[TUR$5upVXV4$U[*;a![,TS
-	nUnTS-(aSUS
3nXV4$U[.:XaS[0[2[44TnSTnXV4$U[6:Xa+S	R9U4Sj[;[<555nXV4$U[>:Xa[@Tup�XV4$U[B:Xa[DTnXV4$U[F:Xa	[HTnXV4$)Nr�r?rdz + NULLz + NULL|selfr>zto Lirir�rfzbool(r�)r�rQr��asciic3sH># �UHupTSU--(dMUv� M g7f)rdNru)Z.0rpZsr�s   �r-Z	<genexpr>Z1ArgResolver.get_argval_argrepr.<locals>.<genexpr>Ts&����$5�$�!�'*�a��d�|�%&�A�$5�s�"�	")%roZ__getitem__r��hasconst�_get_const_infor�Zhasnamer�_get_name_infor r!ZhasjumpZhasexcr�r�r$r%r&r�ZhaslocalZhasfreeZ
hascompareZcmp_oprrQr�r�rrnr��FUNCTION_ATTR_FLAGSrrr"rr#r)rwr�r�r��get_namer�r�r�r�Zarg1Zarg2Zval1Zargrepr1Zval2Zargrepr2�_s  `             r-�get_argval_argreprZArgResolver.get_argval_argrepr!s����:�:�-�4�4�:�:�3I�3I��������|���?�
�F��x��"1�$��T�^�^�"L���^���]����;�&�&4�S�!�V�X�&F�O�F��a��W�%,�I�W�"5��T���S�Y�&�&4�S�!�V�X�&F�O�F��a��W�%,�I�\�":��L���K�_�,�&4�S�!�V�X�&F�O�F��a��W�%,�I�\�":��D���A'5�S�(�&C�O�F�G�@���?���D�F�N��2�2�2�s�F�C���/�/��7�� ���,��6���5�-�/C�EZ�[�[��a�x���R�x��!/��6M�6M�!N���!/��6M�6M�!N���"�T�/�H�4�����(���'��!�T�W�_�"0��d�6M�6M�"N���$���#��#���q��)�� ����8� %�g�Y�a�0�G������&���T�5�1�#�6��6�s�;������/�/��)�)�$5�)�<O�2P�$5�5�����
��"�$�S�\�
��
���	�)�)�,�S�1������)�)�,�S�1����rs)ror�r�rC)NNNN)	rXrzr{r|r�r�r�r�r}rursr-rTrTs��+�
�1�;rsrT)�
first_liner2r3c	s0�[U5n[[U55nUbXR-
nOSnURn[URURUR[U5S9n[[XC5UUUR5UUS9$)a�Iterator for the opcodes in methods, functions or code

Generates a series of Instruction named tuples giving the details of
each operations in the supplied code.

If *first_line* is not None, it indicates the line number that should
be reported for the first source line in the disassembled code.
Otherwise, the source line information (if any) is taken directly from
the disassembled code object.
rr���
linestartsr��co_positions�
original_coderD)
r�dictr�co_firstlinenor=rTr�r��_varname_from_opargrO�_get_instructions_bytesr�r�)	rYr�r2r3r�r�r�r�rDr�r-rr^s���
�!�	�B��n�R�(�)�J��� �#4�#4�4�����J�J�M�����%'�[�[�24�2H�2H�*:�=�*I�K�L�#�?�2�#@�.8�/:�02���0A�1>�0<�>�>rscs �[nUbX!nU$)z�Helper to get the value of the const in a hasconst op.

Returns the dereferenced constant if this is possible.
Otherwise (if it is a LOAD_CONST and co_consts is not
provided) returns the dis.UNKNOWN sentinel.
��UNKNOWN)r�r�r�r�rqr-�_get_const_valuer�|s���F�������MrscsL�[XU5nU[La[U5OSnX44$)z�Helper to get optional details about const references

Returns the dereferenced constant and its repr if the value
can be calculated.
Otherwise returns the sentinel value dis.UNKNOWN for the value
and an empty string for its repr.
r�)r�r�r�)r�r�r�r�r�rcr-r�r��s*���b�y�
1�F�$�G�3�d�6�l��G��?�rscs0�UbU"U40UD6nX34$[S4$)z�Helper to get optional details about named references

Returns the dereferenced name as both value and repr if the name
list is defined.
Otherwise returns the sentinel value dis.UNKNOWN for the value
and an empty string for its repr.
r�r�)Z
name_indexr�Z	extrainfor�rqr-r�r��s+�����*�2�	�2���~����{�rscs��[U5nUS-nUS-(a#US-n[U5nX!S--nUS-(aM#U$)Ni?rhi)�next)�iteratorZbZvalr�r-�
_parse_varintr��sJ���X��A�
�b�&�C�
�B�$���	����N����t����B�$�$��Jrsc	s,�[UR5n/n[U5S-n[U5S-nX4-n[U5S-n[U5nUS-	n[US-5n	UR	[X5XhU	55 Mj![a Us$f=f)Nr?rd)�iterZco_exceptiontabler�Zboolrkr�Z
StopIteration)
r�r�Zentriesr�Zlengthr�r�Zdlr1r��
          r-�_parse_exception_tabler��s����D�*�*�+�H��G���!�(�+�A�-�E�"�8�,�Q�.�F��.�C�"�8�,�Q�.�F��x�(�B��!�G�E���A��J�E��N�N�/��F�5�Q�R��������s�A+B�B�Bcs�[US;$)N)rZJUMP_BACKWARD_NO_INTERRUPTr�)r�rxr-r�r��s���"�:�8�8�8rsc#s�# �U=(d UnU=(d [S5nSnSnSn[U5GH,up�p�UbX�;nU(aXnUbXr-nOSn[[US56n
[	U5nX	nU(aURX�U	5unnO
U[
U5nn[[U5n[U5Hn[US5 M U(aO/n[[UR5H*unnX	S-U	S-SU--nURUUU45 M, OSnU(aURU	5OSn[[UX�UUX�XhUU
U5v� GM/ g7f)z�Iterate over the instructions in a bytecode string.

Generates a sequence of Instruction namedtuples giving the details of each
opcode.

ruFNr?)r��_unpack_opargsr�r�r�r�r�r�r�rjrr�rIrkr�r)r�r�r�r�r�rDr�Zlocal_line_numberr�r�r�r�r�r�r�r�r�r�r�r�r+r�r�r�s                        r-r�r��s����"�)�T�M��+�4��8�L��K����K�)7�
�)F�"8�%��b��!� �.�K��$.�$6�!� �,�/�=��"���t�L�"�5�6�	���|��
�\���*�=�=�b�v�N�O�F�G�!�4��9�G�F� ��T�!2�3���v��	#�A���r�"�	#���J�+�F�4�L�9�?�?�A�
6�
��d��Q�J���
�Q��X�(=�>���!�!�4��t�"4�5�
6��J�=I��1�1�&�9�t���+�b�/�2�F�G� ����J�8�	8�A"8�s�E#E%c
s��[[U55n[U5n[URUS9nS[[
[U555-n	[U[U5U(a4[[
[[UR5S-
S555OSU	US9n
[URURURUS9n[[X5XXpR!5URX�S9 g	)
zDisassemble a code object.)r�r>r?r@rr�r�)r�r�r�rDrEN)r�rr�rOr=rPrQrR�_get_lineno_widthrSrTr�r�r�rUr�r�)r�r�r0r2r3r4r�r�rCrBrErD�            r-rr�s����n�R�(�)�J�.�r�2��!�"�*�*�@Q�R�J��c�#�c�*�o�.�/�/�K��t�'8��'D�S_�s�3�s�3�r�z�z�?�Q�3F��/M�+N�'O�ef�&1�&1�	3�I�
����%'�[�[�24�2H�2H�*4�6�L���r�4�e�):���IZ�%'�Z�Z�l�arsc
s��[XX4US9 UbUS:�aRUbUS-
nURH9n[US5(dM[US9 [SU<S3US9 [	XaX#XES9 M; gg)	Nr5rrdr=r<zDisassembly of r�r/)rr�rGrLrN)r�r0r1r2r3r4rYr�r-rNrNss����;�Xd�e��}���	����A�I�E����	�A��q�)�$�$��4� ��a�1��=�&���%��		�"rsrucs��[[U55n[U5nUH;upEn nURU5 URU5 URU5 M= [U5n[	[U55VV	s0sH
up�X�S-_M n
nn	UH<nX�R
UlX�RUlX�RUl
M> U
$s sn	nf)Nrd)ZsetrZaddrHr�r�r�r�r�r�r�)r�r�Zjump_targets�labelsr�r�r�r�rpr�rCZer�r-rOrOs����z�-�0�1�L�
��
�F�$5�� ��F�A�q��
�
�5���
�
�3���
�
�6����F�^�F�1:�6�&�>�1J�K�+�1�&�A�#�+�K�J�K�
�.��"�7�7�+��
� ���'���#�H�H�-���.����Ls�Cz  --cs�Ucg[[SUR55SS9nUS:Xag[S[[	U555nU[[
5:a#SUR5;a[[
5nU$)Nr�����)�defaulti)rSZfilterZvaluesrPrQr�)r�Z	maxlinenor�r�r-r�r�+sq������F�4��!2�!2�!4�5�r�B�I��B����q�#�c�)�n�-�.�L��c�*�o�%�$�*�2C�2C�2E�*E��:����rs)r�r�r�r�rDrEc	s2�[XUUUUS9n	[X�X�S9 g)Nr�)r�)r��print_instructions)
r�r�r�r�r�r�r�rDrE�instrsr�r-rUrU8s)��%�T�7B�8D�9F�8D�	F�F��v�)�Irsc
s��UHfnURUs=:*=(a8 URS[[[UR55--:*Os nURXE5 Mh UR
U5 gr�)r�r�r�r�r�r�r�)r�r�rEr�r�Zis_current_instrr�r-r�r�Isr���=�� �<�<�5�W�W��|�|�a�/�+�h�u�|�|�>T�2U�"V�V�V�W���#�#�E�<�	=��#�#�$5�6rscs0�[[US540UD6 g)z<Compile the source string, then disassemble the code object.z<dis>N)rNr.)r*Zkwargsr,r-rVrVRs���<���8�C�F�Crsrgr?rdc#s|# �SnSnSn[S[U5S5H�nU(aUS-nMXn[U5n[[U5nU[
;a2XS-U-nU[:XaUS-OSnU[:�aUS[--nOSnSnU[:Xa
US-
nXDXW4v� M�XBS--
nXHXW4v� SnM� g7f)Nrr?rdre)rjrPr�r�r�Zhasarg�EXTENDED_ARG�
_INT_OVERFLOW)	r�Zextended_argZextended_args_offsetr�rpr�r�r�r�r�r-r�r�^s�����L���
�F�
�1�c�$�i��
#�%����a�K�F��
�W����|�� ��T�!2�3���6�>���s�)�l�*�C�)-��)=�C�1�H�1�L��}�,���M� 1�1����C��L��<�� �A�%� ���/�!��A�5�5�L��B�,�,�#$� �3%�s�B:B<cs��/n[U5H4up#pEUcM[XEU5nUcMXa;dM#URU5 M6 U$)zXDetect all offsets in a byte code which are jump targets.

Return the list of offsets.

)r�r�rk)r�r�r�r�r�r�r�r�r-rr}sT���F�,�T�2�%���2��?�$�R�f�5�E��}���"��
�
�e�$�
%��Mrsc#s^# �SnUR5Hup#nXALdMUnX$4v� M g7f)z�Find the offsets in a byte code which are start of lines in the source.

Generate pairs (offset, lineno)
lineno will be an integer or None the offset does not have a source line.
FN)Zco_lines)r�Zlastliner�r�Zlinercr-rr�s>����H� �M�M�O����D����H��+����s�-�-c	#s�# �[SnURnURn[UR5VVVs/sHu pEnU[
:wdMXV4PM nnnn[
U5HqunupYXQ:XdMUS:�dMXxS-
n
XxS-
nU
S[;dM4US[;dMC[USUSU5n[U
SU
SU5n
X9X�4v� Ms gs snnnf7f)z�Find import statements in the code

Generate triplets (name, level, fromlist) where
name is the imported module and level, fromlist are
the corresponding args to __import__.
�IMPORT_NAMEr?rdrN)	�opmapr�r�r�r=r�r�r�r�)r�r�Zconstsror�r�r�Zopargsrpr�Zfrom_opZlevel_opZlevelZfromlistrZr-�
_find_importsr�s�����
�&�K�
�\�\�F��K�K�E�-;�B�J�J�-G�)�)�M�A�q�c��<�'��r�i�)�F�)�#�F�+�6���;�B�
���a���q�S�k�G���c�{�H���
�h�&�8�A�;�(�+B�(��!��h�q�k�6�J��+�G�A�J���
�F�K���|�U�5�5�6��)�s.�;C%�C�C�C%�7C%�?C%�C%�+:C%c#s�# �[S[S1nURn[UR5Hu p4nXA;dMX%v� M g7f)zTFind names of variables which are written in the code

Generate sequence of strings
Z
STORE_NAMEZSTORE_GLOBALN)rr�r�r=)r�Z	STORE_OPSror�r�r�r�r-�_find_store_namesr�sT���	�l��
�n���I�

�K�K�E�'��
�
�3��
��1�#�
�?��*���s�>A�Acs`�\rSrSrSrSSSSSS.SjrSrSr\SSS	.S
j5r	Sr
SrS
rg)ri�z�The bytecode operations of a piece of code

Instantiate this with a function, method, other compiled object, string of
code, or a code object (as returned by compile()).

Iterating over this yields the bytecode operations as Instruction instances.
NF)r��current_offsetr2r3r4cs �[U5=UlnUcURUlSUlOX lX'R-
Ul[[
U55UlXlX0l	[U5UlX@lXPl
X`lgr�)r�codeobjr�r��_line_offsetr�r�_linestarts�_original_objectrr�r�r2r3r4)rwrYr�rr2r3r4r�r�r-r�ZBytecode.__init__�s���,�Q�/�/���r��� �/�/�D�O� !�D��(�O� *�->�->� >�D����r� 2�3��� !��,��!7��!;���&�� �
�(�rsc	s6�URnURn[X R5n[	UR
URURUS9n[[XR5URURUR5UUS9$)Nr�r�)rr=rOr�rTr�r�r�r�r�r3rrr�)rwr�r�rCrDrcr-�__iter__ZBytecode.__iter__�s���
�\�\���
�
�
�%�m�5K�5K�L�
�"�R�\�\�)+���68�6L�6L�.8�:��'��r�=�=�'I�26�2B�2B�37�3D�3D�46�O�O�4E�5B�4@�B�	Brscsb�SRURRUR5$)Nz{}({!r}))Zformat�	__class__rXrrvrxr-ryZBytecode.__repr__�s*��� � ����!8�!8�!%�!6�!6�8�	8rs)r2r3cs��UR(aURnUR(aMU"URRURX#S9$)z.Construct a Bytecode from the given traceback )rr2r3)r^r_r`ra)Zclsrbr2r3rqr-�from_tracebackZBytecode.from_traceback�sA���j�j����B��j�j�j���K�K���r�{�{��
�	
rscr�)z3Return formatted information about the code object.)r�rrvrxr-�infoZ
Bytecode.info�s�� ����.�.rsc
sB�URnURb
URnOSn[R"5n[	XR
5nUR(a*[[[[U5S-
S555OSn[URUR5nS[[[U555-n[U[UR5UUUR UR"S9n[%UR&UR(UR*US9n	[-UURUR UURUR/5URU	US	9	 UR15sSSS5 $!,(df   g=f)
z3Return a formatted view of the bytecode operations.Nr�r?r@rr>)r0r�rArBr�r2r�)r�r�r�r�r�r�rDrE)rrr�r�r�r3r4rPrQrSrOr=r�rRr�rrr2rTr�r�r�rUr�r�)
rwr�r�r�r�rArCrBrErDr�r-rZBytecode.dis�sS��
�\�\�����*��(�(�F��F�
�[�[�]�	%�f�"�2�}�}�5�D�AE�AR�AR�3�s�3�s�4�y�1�}�d�#;�<�=�XY�L�*�"�*�*�d�6L�6L�M�J��c�#�c�*�o�"6�7�7�K�!�v�/@��AQ�AQ�/R�/;�.9�.2�.?�.?�.2�.>�.>�@�I�'����-/�[�[�:<�:P�:P�2<�>�L�
�t�*.�*:�*:�+/�+<�+<�%+�15�1G�1G�,.�O�O�,=�-/�Z�Z�,8�)2�
4��?�?�$�7	%�	%�	%�s�EF�
F)r2rrrr4r�r�rr3rr	)
rXrzr{r|r�r�rry�classmethodr
rrr}rursr-rr�sI���)-�T�u�_d�sx�)� 
B�8��/4�u�
��
�/�"%rsrcs�SSKnUR5nURSSSSS9 URSSSS	S9 URS
SSS
9 UR5nURS:Xa+Sn[
RRR5nO;URn[URS5nUR5nSSS5 [WUS5n[XbRURS9 g!,(df   N:=f)Nrz-Cz
--show-cachesZ
store_truezshow inline caches)ZactionZhelpz-Oz--show-offsetszshow instruction offsets�infileZ?Z-)Znargsr�z<stdin>Zrbr()r2r4)�argparseZArgumentParserZadd_argumentZ
parse_argsr
r\ZstdinZbufferZreadZopenr)rr2r4)rZparserZargsr+r*r
r�r�r-�mainrs����
�
$�
$�
&�F�
����o�l�1��3�
����.�|�7��9�
�����S��9�����D��{�{�c�������!�!�&�&�(���{�{��
�$�+�+�t�
$�	#���[�[�]�F�	#��6�4��(�D���*�*��9J�9J�K�	#�	#�s�7C<�<
D
Z__main__r�)NrNNN)r�)ru)r�N)sr�r\ZtypesZcollectionsr�r�rZ_opcodes_allrrrrrrrZ_opcoder	Z
MethodTypeZFunctionTypeZCodeTyperZstaticmethodrWrKrrrr�rrrrrrrrr r!r"r#r$r%r&r'Zlistr�r�r�r�rIr+r�r�r.rr
rlrrrtr�rr�r�r
r�rZ
namedtupler�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�rrRrTrr�r�r�r�r�r�r�rrNrOr�r�rUr�rVrZ	_INT_BITSr�r�rrrrrrrX)ZbaseZfamilyZspecializeds000r-�<module>rs���6�
���	��	�	�	�!�:�<H�I������� 2� 2�E�N�N��<��/�
��o�&�
��7�8��J���'�(��
�<�
 �
��^�$���M�"���+��	��o�&�
������V�}���+��	��)�*���+�,���+�,���1�2���3�4���5�6��
�g����6�l��
�%�[�
�"�(�(�*��H�D�"��K��O��J�t��	�+;�*@�*@�*B���&�$�V\��GR�������)�4*��D�e�e��4*�lC�4�U�U�QV�C�"	���������������
�*��&�.B��.2��@�$�
�"�"����V�a�Z�	
�	��%�%��
� �!��&B�����:�����S�����T�����Q�����Q�����,�
���!�$_���� �#l���� �e�����!s�����"k�����&�1�1�2L�"�$��	�3�	��
���0��$E!�,�E!�Pa^�a^�HQ�Q�f'+��u�>�<�
���� 8�PT�=A�38�la�d���"�a�((,�4�U�UZ�in��
��
�
�J�&'�2�$(��$(�D�J�"7�D�	��
�	��i�!�m�$�
�%�>� �6�,
� Z%�Z%�zL�(�z���F���ks�M