astx.buffer
astx.buffer
Source: packages/astx/src/astx/buffer.py
title: ASTx low-level buffer AST nodes.
summary: >-
Provide internal nodes that host compilers can target for the buffer/view
substrate without defining a user-facing array API.Classes
BufferOwnerType(OpaqueHandleType)
title: Internal opaque buffer owner handle type.BufferViewType(AnyType)
title: Internal canonical low-level buffer view descriptor type.
attributes:
element_type:
type: astx.DataType | NoneBufferViewDescriptor(astx.base.DataType)
title: Internal low-level buffer view descriptor literal.
attributes:
metadata:
type: Any
type_:
type: BufferViewTypeMethods
get_struct(self, simplified: bool=False) -> astx.base.ReprStruct
title: Return the structured representation.
parameters:
simplified:
type: bool
returns:
type: astx.base.ReprStructBufferViewIndex(astx.base.DataType)
title: Internal low-level indexed read through a buffer view.
summary: >-
Reads one scalar element by computing offset_bytes plus the sum of
index*stride byte offsets over the canonical buffer view descriptor.
attributes:
base:
type: astx.AST
indices:
type: list[astx.AST]
type_:
type: astx.DataTypeMethods
get_struct(self, simplified: bool=False) -> astx.base.ReprStruct
title: Return the structured representation.
parameters:
simplified:
type: bool
returns:
type: astx.base.ReprStructBufferViewStore(astx.base.DataType)
title: Internal low-level indexed store through a buffer view.
summary: >-
Stores one scalar element by computing the canonical descriptor element
address. This is not a user-facing array mutation API.
attributes:
base:
type: astx.AST
indices:
type: list[astx.AST]
value:
type: astx.AST
type_:
type: astx.Int32Methods
get_struct(self, simplified: bool=False) -> astx.base.ReprStruct
title: Return the structured representation.
parameters:
simplified:
type: bool
returns:
type: astx.base.ReprStructBufferViewWrite(astx.base.DataType)
title: Internal low-level raw byte write through a buffer view.
summary: >-
Writes one 8-bit integer at offset_bytes + byte_offset. This is not a
generic typed element store or user-facing array mutation API.
attributes:
view:
type: astx.AST
value:
type: astx.AST
byte_offset:
type: int
type_:
type: astx.Int32Methods
get_struct(self, simplified: bool=False) -> astx.base.ReprStruct
title: Return the structured representation.
parameters:
simplified:
type: bool
returns:
type: astx.base.ReprStructBufferViewRetain(astx.base.DataType)
title: Internal explicit runtime retain for a buffer view owner.
attributes:
view:
type: astx.AST
type_:
type: astx.Int32Methods
get_struct(self, simplified: bool=False) -> astx.base.ReprStruct
title: Return the structured representation.
parameters:
simplified:
type: bool
returns:
type: astx.base.ReprStructBufferViewRelease(astx.base.DataType)
title: Internal explicit runtime release for a buffer view owner.
attributes:
view:
type: astx.AST
type_:
type: astx.Int32Methods
get_struct(self, simplified: bool=False) -> astx.base.ReprStruct
title: Return the structured representation.
parameters:
simplified:
type: bool
returns:
type: astx.base.ReprStruct