Serialize
Applicability
Product |
Supported or Not |
|---|---|
√ |
|
√ |
|
√ |
|
√ |
|
√ |
Header File
#include <graph/kernel_launch_info.h>
Function Usage
Serializes KernelLaunchInfo into a data stream.
Prototype
1 | std::vector<uint8_t> Serialize() |
Parameters
None
Returns
Serialized data stream.
Constraints
None
Examples
1 2 3 4 5 6 7 8 9 10 11 | graphStatus Mc2GenTaskCallback(const gert::ExeResGenerationContext *context, std::vector<std::vector<uint8_t>> &tasks) { ... // Create a wait task. auto wait_task = KernelLaunchInfo::CreateHcomWaitTask(context); wait_task.SetStreamId(attach_stream_id); // Perform serialization. tasks.insert(tasks.begin() + aicore_index, wait_task.Serialize()); aicore_index++; ... } |
Parent topic: KernelLaunchInfo