REGISTER_CUSTOM_PASS
Applicability
Product |
Supported |
|---|---|
Atlas 350 Accelerator Card |
√ |
√ |
|
√ |
|
√ |
|
√ |
|
√ |
Header File
#include <register/register_custom_pass.h>
Function Usage
Developers can register the graph modification function with the framework. The framework calls the custom graph modification pass at the beginning of build and calls REGISTER_CUSTOM_PASS to register the custom pass.
Prototype
1 | REGISTER_CUSTOM_PASS(name) |
Parameters
Parameter |
Input/Output |
Description |
|---|---|---|
name |
Input |
Name of a custom pass. |
Returns
None
Restrictions
The call starts with REGISTER_CUSTOM_PASS and uses periods (.) to connect APIs such as CustomPassFn. For example:
1 2 | #include "register/register_custom_pass.h" REGISTER_CUSTOM_PASS("pass_name").CustomPassFn(CustomPassFunc); |
Parent topic: Basic Data Structures and APIs of Graphs