
    9i                         % S SK JrJr  S SKJr   " S S\5      r " S S\5      r " S S5      r\" S	\" 5       S
9r\\   \	S	'   S\4S jr
\" S	\" 5       S
9q\\	S'   S\\   4S jrg)    )OptionalProtocol)
ContextVarc                   "    \ rS rSrS\4S jrSrg)Buffer   returnc                     g N )selfs    Z/var/www/html/land-doc-ocr/venv/lib/python3.13/site-packages/triton/runtime/_allocation.pydata_ptrBuffer.data_ptr           r   N)__name__
__module____qualname____firstlineno__intr   __static_attributes__r   r   r   r   r      s    # r   r   c                   4    \ rS rSrS\S\S\\   S\4S jrSrg)		Allocator   size	alignmentstreamr	   c                     g r   r   r   r   r   r   s       r   __call__Allocator.__call__   r   r   r   N	r   r   r   r   r   r   r   r!   r   r   r   r   r   r      s'    S S (3- F r   r   c                   4    \ rS rSrS\S\S\\   S\4S jrSrg)	NullAllocator   r   r   r   r	   c                     [        S5      e)NzxKernel requires a runtime memory allocation, but no allocator was set. Use triton.set_allocator to specify an allocator.)RuntimeErrorr    s       r   r!   NullAllocator.__call__   s     O P 	Pr   r   Nr#   r   r   r   r%   r%      s,    PS PS P(3- PF Pr   r%   
_allocator)default	allocatorc                 .    [         R                  U 5        g)zt
The allocator function is called during kernel launch for kernels that
require additional global memory workspace.
N)r*   setr,   s    r   set_allocatorr0      s    
 NN9r   _profile_allocatorc                 .    [         R                  U 5        g)z|
The profile allocator function is called before kernel launch for kernels
that require additional global memory workspace.
N)r1   r.   r/   s    r   set_profile_allocatorr3   &   s     9%r   N)typingr   r   contextvarsr   r   r   r%   r*   __annotations__r0   r1   r3   r   r   r   <module>r7      s    % % "X  P P %/|]_$U
Jy! UY  !+< Q I Q&Xi%8 &r   