+
    :i                     (   ^ RI t ^ RIt^ RIt^ RIt^ RIHt ^ RIt^ RIt^ RI	H
t
HtHtHt ^ RIHt ^ RIHtHt ]P&                  ! ]
P(                  P*                  4      tR t ! R R]4      t ! R R	]4      t]R
8X  d   ]P6                  ! 4        R# R# )    N)typestypingcgutilscpu)global_compiler_lock)TestCaserun_in_subprocessc                 8    \         P                  ! \        V 4      # N)irConstantmachine_int)ns   &V/var/www/html/photoedit/myenv/lib/python3.14/site-packages/numba/tests/test_cgutils.pymachine_constr      s    ;;{A&&    c                      a  ] tR t^t o R t]P                  R 4       tR tR t	]P                  RR l4       t
]P                  R 4       tR tR tR	tV tR
# )StructureTestCasec                f    \         P                  ! 4       p\        P                  ! V4      V n        R # r   )r   Contextr   
CPUContextcontext)selftyping_contexts   & r   setUpStructureTestCase.setUp   s    )~~n5r   c              #  6  a aaa	"   \         P                  ! \        \        .V,          4      p\        P                  ! \        P
                  .\        P
                  3V,          O5!  oS P                  P                  R 4      o	\        P                  ! S	VS P                  4       4      oSP                  '       g   Q hSP                  R4      p\         P                  ! V4      pR.p\        VVV	V 3R l4       pS P                  VSP                  V3x  R# 5i) entryTc                     < SP                   P                  4       pVP                  R SP                  4       ,          4      pVP	                  S4       VP                  SP                  4      pS! V4      pV! V !  # )ztest_module.%s)r   codegencreate_libraryidadd_ir_moduleget_pointer_to_functionname)	argsr!   librarycptrcfuncctypes_fntyfunctionmoduler   s	   *    r   	call_func5StructureTestCase.compile_function.<locals>.call_func)   sg    ll**,G,,-=	-IJG!!&)228==AD%E$<r   N)r   FunctionTyper   ctypes	CFUNCTYPEc_size_tr   create_moduler   get_or_insert_functionr#   is_declarationappend_basic_block	IRBuilderr   r'   )
r   nargs	llvm_fntyentry_blockbuilderfirstr.   r+   r,   r-   s
   f&     @@@r   compile_function"StructureTestCase.compile_function   s     OOK+1FG	&&v B'-&85&@B++B/11&)TWWYO&&&&&11':,,{+		  
	  llGX]]I==s   DDc                    \        V\        4      '       g   Q h\        P                  P                  p\        P
                  .Vn        \        P                  Vn        V! V4      # r   )	
isinstance	bytearrayr1   	pythonapiPyByteArray_AsString	py_objectargtypesc_void_prestype)r   baba_as_strings   && r   get_bytearray_addr$StructureTestCase.get_bytearray_addr5   sN    "i((((''<<!'!1!1 2%Br   c                <   V P                  ^4      ;_uu_ 4       w  rr4VP                  V^ ,          V^,          4      pVP                  V4       RRR4       V P                  X! ^R4      ^4       V P                  V! ^^4      ^4       R#   + '       g   i     LD; i)   N)r>   addretassertEqual)r   r   r<   r'   callress   &     r   test_compile_function'StructureTestCase.test_compile_function<   sz    ""1%%)G'D++d1gtAw/CKK & 	aa(aQ'	 &%s   5BB	c              #    "   V P                  ^4      ;_uu_ 4       w  rErgV! WE4      pVP                  V^ ,          \        V4      4      p	VP                  V	\        P
                  ! VP                  4      4      p	V! WEV	R7      pWEWh3x  VP                  \        P                  ! \        ^ 4      4       RRR4       X! V P                  V4      4       R#   + '       g   i     L); i5i)   )refN)r>   rP   r   inttoptrr   PointerType_typerQ   r   r   rK   )
r   struct_classbufoffsetr   r<   r'   rS   instsptrs
   &&&&      r   run_struct_access#StructureTestCase.run_struct_accessD   s     ""1%%)G'D1D;;tAwf(=>D##D"..*DEDd;DD..KKK34 & 	T$$S)* &%s   C(BC4!C(C%	 C(c              #  <  "   \        R 4      ^(,          pVR,          p^pV P                  WV4      ;_uu_ 4       w  rxrWxV
3x  RRR4       V P                  WE4       \        P                  ! W%V.VO5!   V P                  WE4       R#   + '       g   i     LM; i5i)   !:NNNN)rB   rb   assertNotEqualstruct	pack_intorR   )r   r]   
struct_fmtstruct_argsr^   expectedr_   r   r<   r'   r`   s   &&&&       r   run_simple_struct_test(StructureTestCase.run_simple_struct_testQ   s      o"q6##Lv>>-$D(( ? 	C*vDD' ?>s   8B
B	AB	B	Bc                p    ! R  R\         P                  4      pRpV P                  WR4      ;_uu_ 4       w  r4p\        P                  ! \        P
                  ! ^ 4      R4      Vn        \        P                  ! \        P
                  ! ^4      R4      Vn        RRR4       R#   + '       g   i     R# ; i)c                   N    ] tR t^btR]P
                  3R]P                  3.tRtR# ),StructureTestCase.test_int_fields.<locals>.Sab N)	__name__
__module____qualname____firstlineno__r   int32uint16_fields__static_attributes__rs   r   r   Srp   b   s!    U[[)U\\*,Gr   r|   z=iHxV4ͫ  N)r}   r~   )r   	Structurerl   r   r   IntTyperq   rr   r   r|   fmtr   r<   r`   s   &     r   test_int_fields!StructureTestCase.test_int_fieldsa   sz    	,!! 	, ((1EFF'$[[B<DF[[B8DF GFFFs   A$B$$B5	c                l    ! R  R\         P                  4      pRpV P                  WR4      ;_uu_ 4       w  r4p\        P                  ! \        P
                  ! 4       R4      Vn        \        P                  ! \        P                  ! 4       R4      Vn        RRR4       R#   + '       g   i     R# ; i)c                   N    ] tR t^mtR]P
                  3R]P                  3.tRtR# ).StructureTestCase.test_float_fields.<locals>.Srq   rr   rs   N)	rt   ru   rv   rw   r   float64float32rz   r{   rs   r   r   r|   r   m   s!    U]]+U]]+-Gr   r|   z=dfGz?=
ףp=@N)r   r   )	r   r   rl   r   r   
DoubleTyperq   	FloatTyperr   r   s   &     r   test_float_fields#StructureTestCase.test_float_fieldsl   st    	-!! 	- ((>>'$[[$7DF[[6DF ?>>>s   A"B""B3	)r   N)r   )rt   ru   rv   rw   r   
contextlibcontextmanagerr>   rK   rU   rb   rl   r   r   r{   __classdictcell____classdict__s   @r   r   r      sq     6 > >2 ( 
+ 
+ ( (	9	7 	7r   r   c                   *   a  ] tR t^xt o RtR tRtV tR# )TestCGContextz/Tests for code generation context functionalityc                    R pRV R2p\        V4      w  r4V P                  \        V4      VP                  4       4       R# )i@ az  if 1:
        from numba import njit, types
        from numba.extending import intrinsic

        @intrinsic
        def printf(tyctx, int_arg):
            sig = types.void(int_arg)
            def codegen(cgctx, builder, sig, llargs):
                cgctx.printf(builder, "%d\n", *llargs)
            return sig, codegen

        @njit
        def foo():
            printf(z)

        foo()
        N)r	   assertInstrdecode)r   valuecodeout_s   &    r   test_printfTestCGContext.test_printf{   sG      7 	$ #4(c%j#**,/r   rs   N)rt   ru   rv   rw   __doc__r   r{   r   r   s   @r   r   r   x   s     90 0r   r   __main__)r   r1   rg   sysllvmlite.irr   numpynpunittest
numba.corer   r   r   r   numba.core.compiler_lockr   numba.tests.supportr   r	   r   intpbitwidthr   r   r   r   rt   mainrs   r   r   <module>r      sx       
    2 2 9 ; jj,,-'`7 `7F0H 0> zMMO r   