# ProtonOps ### `proton.allocate_event` (triton::proton::AllocateEventOp) _Allocate a named asynchronous event_ Syntax: ``` operation ::= `proton.allocate_event` $name attr-dict `:` type($event) ``` Allocate a static correlation identity for an asynchronous event without recording a timestamp. Each event operation remains distinct even when names are reused; its write effect prevents common-subexpression elimination from merging those identities. Interfaces: `InferTypeOpInterface`, `MemoryEffectOpInterface (MemoryEffectOpInterface)` Effects: `MemoryEffects::Effect{MemoryEffects::Write on ::mlir::SideEffects::DefaultResource}` #### Attributes:
AttributeMLIR TypeDescription
name::mlir::StringAttrstring attribute
#### Results: | Result | Description | | :----: | ----------- | | `event` | 32-bit signless integer | ### `proton.event` (triton::proton::EventOp) _Record an asynchronous event_ Syntax: ``` operation ::= `proton.event` (`start` $isStart^):(`end`)? $event attr-dict `:` type($event) ``` Record the timestamp at which an asynchronous transaction starts or ends. The event identifies the corresponding endpoints even when they execute in different regions. Interfaces: `MemoryEffectOpInterface (MemoryEffectOpInterface)` Effects: `MemoryEffects::Effect{MemoryEffects::Read on ::mlir::SideEffects::DefaultResource, MemoryEffects::Write on ::mlir::SideEffects::DefaultResource}` #### Attributes:
AttributeMLIR TypeDescription
isStart::mlir::UnitAttrunit attribute
#### Operands: | Operand | Description | | :-----: | ----------- | | `event` | 32-bit signless integer | ### `proton.record` (triton::proton::RecordOp) _Record an event_ Syntax: ``` operation ::= `proton.record` (`start` $isStart^):(`end`)? $name attr-dict ``` This operation annotates a region of IR where events are recorded. Events can be classified as hardware or software events. Hardware events are provided by the hardware performance counters obtained in later passes that convert Triton to target-specific IR. Software events are provided by the user or the compiler. Example: ```mlir proton.record start "name0" ... proton.record end "name0" ``` Scope names cannot be reused within the same function. Interfaces: `MemoryEffectOpInterface (MemoryEffectOpInterface)` Effects: `MemoryEffects::Effect{MemoryEffects::Read on ::mlir::SideEffects::DefaultResource, MemoryEffects::Write on ::mlir::SideEffects::DefaultResource}` #### Attributes:
AttributeMLIR TypeDescription
isStart::mlir::UnitAttrunit attribute
name::mlir::StringAttrstring attribute