You can not select more than 25 topicsTopics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.
Refactor the original "PassManager" class, and derive the "GraphKernelPassManager"
GraphKernel's ir files are dumped into a new sub-directory "graph_kernel" in the original "verbose_ir_files"
All GraphKernel's passes are divided into 3 levels, and controlled by the flag "opt_level" by default.
when the opt_level is greaterequal to the pass's level, this pass will run.
The default "opt_level" is 2 when GraphKernel is enabled.
Levels:
1. Basic features, like cluster, splitter, and some preprocess, postprocess.
2. All stable features, mainly includes the optimization passes.
3. Experimental features, like stitch-fusion, parallel-fusion.
The two flags "enable_pass" and "disable_pass" are available in this commit.
User can manually enable some passes when it's disabled by "opt_level", or disable the enabled passes,
by specifying that pass in this format: "stage_id.pass_id" or "stage_name.pass_name", multiple passes are separated by comma(",")
the stage/pass index and stage/pass name can be found from the ir filename.
e.g. "--enable_pass=cluster.graph_kernel_expander,1.1,1.2"
Others:
1. the pass "tensor_promotion" is not useful, remove it.
2. put the pass "InsertPadOps" before "ArithmeticSimplify".