+
    ‘°³j2  ã                  óÔ   € ^ RI Ht ^ RIt^ RItRRRR/t]P                  4        U Uu/ uF  w  rWbK	  	  upp t ! R R]4      tR	 R
 lt	R R lt
R R ltR R ltR R ltR# u upp i )é    )ÚannotationsNÚx64id†  Úarm64idª  c                  ó2   a € ] tR t^tRtR V 3R lltRtV ;t# )ÚUnsupportedArchErrorz?Raised when Python reports an unsupported Windows architecture.c               ó    € V ^8„  d   QhRRRR/# )é   Úplatform_tagÚstrÚreturnÚNone© )Úformats   "Úd/home/luca/screen-checking/.venv/lib/python3.14/site-packages/cuda/pathfinder/_utils/windows_arch.pyÚ__annotate__Ú!UnsupportedArchError.__annotate__   s   € ÷ 
ñ 
 Sð 
¨Tñ 
ó    c                	ó<   <€ Wn         \        SV `	  R V: R24       R# )z)Unsupported Windows Python platform tag: z%; expected 'win-amd64' or 'win-arm64'N)r
   ÚsuperÚ__init__)Úselfr
   Ú	__class__s   &&€r   r   ÚUnsupportedArchError.__init__   s$   ø€ Ø(ÔÜ‰ÑØ7¸Ñ7GÐGlÐmö	
r   )r
   )Ú__name__Ú
__module__Ú__qualname__Ú__firstlineno__Ú__doc__r   Ú__static_attributes__Ú__classcell__)r   s   @r   r   r      s   ø† ÙI÷
ö 
r   r   c               ó   € V ^8„  d   QhRR/# ©r	   r   r   r   )r   s   "r   r   r      s   € ÷ 1ñ 1˜Sñ 1r   c                 ó¦   € \         P                  ! 4       p V P                  4       P                  RR4      pVR8X  d   R# VR8X  d   R# \	        V 4      h)z;Return the current Windows Python interpreter architecture.Ú_Ú-z	win-arm64r   z	win-amd64r   )Ú	sysconfigÚget_platformÚlowerÚreplacer   )Úraw_platform_tagr
   s     r   Úwindows_python_archr+      sN   € ä ×-Ò-Ó/ÐØ#×)Ñ)Ó+×3Ñ3°C¸Ó=€Là�{Ô"Ùà�{Ô"Ùä
Ð/Ó
0Ð0r   c               ó   € V ^8„  d   QhRR/# r"   r   )r   s   "r   r   r   )   s   € ÷ Uñ U¨Sñ Ur   c                 ó®   € \         P                  ! 4       p V P                  4       P                  RR4      pVR9   d   R# VR9   d   R# \	        RV : 24      h)zEReturn the Windows architecture reported by Python's platform module.r$   r%   r   r   z*Unsupported Windows machine architecture: )Úamd64zx86-64)r   Úaarch64)ÚplatformÚmachiner(   r)   ÚRuntimeError)Úraw_machiner1   s     r   Ú#_windows_machine_arch_from_platformr4   )   sV   € ä×"Ò"Ó$€KØ×ÑÓ!×)Ñ)¨#¨sÓ3€GàÐ%Ô%ÙàÐ&Ô&Ùä
ÐCÀKÁ?ÐSÓ
TÐTr   c               ó   € V ^8„  d   QhRR/# )r	   r   z
int | Noner   )r   s   "r   r   r   7   s   € ÷ ' ñ '  ñ ' r   c                 óÔ  € ^ RI p ^ RI Hp  V P                  RRR7      pTP
                  p TP                  pR	Tn        TP                  Tn
        TP                  T P                  TP                  4      T P                  TP                  4      3Tn        TP                  Tn
        TP                  4       pTP                  4       pT! T! 4       T P                  T4      T P                  T4      4      '       g4   T P                  4       pT P!                  T4      p	\	        RT RT	 24      T	hTP"                  #   \         d   p\	        R4      ThRp?ii ; i  \         d     R# i ; i)
zDReturn the native Windows PE machine type, or None on older Windows.N)ÚwintypesÚkernel32T)Úuse_last_errorzGFailed to load kernel32 while detecting the native Windows architecturezVIsWow64Process2 failed while detecting the native Windows architecture (Windows error z): r   )Úctypesr7   ÚWinDLLÚOSErrorr2   ÚGetCurrentProcessÚIsWow64Process2ÚAttributeErrorÚargtypesÚHANDLEÚrestypeÚPOINTERÚUSHORTÚBOOLÚbyrefÚget_last_errorÚWinErrorÚvalue)
r:   r7   r8   ÚexcÚget_current_processÚis_wow64_process2Úprocess_machineÚnative_machineÚ
error_codeÚerrors
             r   Ú_windows_native_machinerQ   7   sd  € ãÝðoà—=‘= ¸D�=ÓAˆð #×4Ñ4ÐðØ$×4Ñ4Ðð $&ÐÔ Ø"*§/¡/ÐÔà�‰Ø�‰�x—‘Ó'Ø�‰�x—‘Ó'ð"ÐÔð
 !)§¡ÐÔà—o‘oÓ'€OØ—_‘_Ó&€NÙÙÓØ�‰�_Ó%Ø�‰�^Ó$÷ò ð
 ×*Ñ*Ó,ˆ
Ø—‘ 
Ó+ˆÜðØ(˜\¨¨U¨Gð5ó
ð ð	ð ×ÑÐøô? ô oÜÐdÓeÐknÐnûðoûô ô Úðús(   ŒD9 ¬E Ä9EÅEÅEÅE'Å&E'c               ó   € V ^8„  d   QhRR/# r"   r   )r   s   "r   r   r   a   s   € ÷ lñ l˜cñ lr   c                 óŒ   € \        4       p V f   \        4       #  \        V ,          #   \         d    \	        RT R 24      Rhi ; i)zKReturn the native Windows machine architecture, ignoring process emulation.Nz.Unsupported native Windows PE machine type: 0xÚ04x)rQ   r4   Ú_WINDOWS_ARCH_BY_PE_MACHINEÚKeyErrorr2   )rN   s    r   Úwindows_machine_archrW   a   sW   € ä,Ó.€NØÒô 3Ó4Ð4ðlÜ*¨>Õ:Ð:øÜô lÜÐKÈNÐ[^ÐK_Ð`ÓaÐgkÐkðlús	   š' §Ac               ó$   € V ^8„  d   QhRRRRRR/# )r	   Úpathr   Útarget_archr   Úboolr   )r   s   "r   r   r   o   s&   € ÷ Gñ G #ð G°Cð G¸Dñ Gr   c                ó¬  € \         P                  V4      pVf   \        RV: 24      h \        V R4      ;_uu_ 4       pVP	                  ^4      R8w  d    RRR4       R# VP                  ^<4       VP	                  ^4      p\        V4      ^8w  d    RRR4       R# VP                  \        P                  VR4      4       VP	                  ^4      R8w  d    RRR4       R# VP	                  ^4      p\        V4      ^8w  d    RRR4       R#  RRR4       \        P                  XR4      T8H  #   + '       g   i     L); i  \         d     R# i ; i)zïReturn whether a Windows Portable Executable (PE) targets the requested architecture.

PE is the file format used for Windows executables and DLLs. This reads the
PE/COFF header's machine field to distinguish x64 images from Arm64 images.
Nz)Unsupported Windows target architecture: Úrbs   MZFÚlittles   PE  )
ÚWINDOWS_PE_MACHINE_BY_ARCHÚgetÚ
ValueErrorÚopenÚreadÚseekÚlenÚintÚ
from_bytesr<   )rY   rZ   Úexpected_machineÚstreamÚpe_offset_bytesÚmachine_bytess   &&    r   Úwindows_pe_matches_archrl   o   s*  € ô 2×5Ñ5°kÓBÐØÒÜÐDÀ[ÁOÐTÓUÐUðÜ�$˜×Ô Ø�{‰{˜1‹~ Ô&Ø÷ Ñð �K‰K˜ÔØ$Ÿk™k¨!›nˆOÜ�?Ó# qÔ(Ø÷ Ñð �K‰KœŸ™ ¸ÓAÔBØ�{‰{˜1‹~ Ô*Ø÷ Ñð #ŸK™K¨›NˆMÜ�=Ó! QÔ&Ø÷ Ñð '÷ ô  �>‰>˜-¨Ó2Ð6FÑFÐF÷! ×ûô ô ÚðúsX   ªE ¾D1ÁE Á 3D1ÂE Â<D1ÃE Ã#"D1ÄE ÄE Ä1E	Ä<E ÅE ÅEÅE)Ú
__future__r   r0   r&   r_   ÚitemsrU   r2   r   r+   r4   rQ   rW   rl   )Úarchr1   s   00r   Ú<module>rp      s|   ðõ #ã Û ð 
ˆ6ØˆVðÐ ð
 C]×BbÑBbÔBdÔeÑBd±°˜wš}ÑBdÒeÐ ô
˜<ô 
õ1õUõ' õTl÷GùóC fs   ¨A$