Skip to content

Add PipelineDescriptor class#78

Open
rengolin wants to merge 1 commit intollvm:mainfrom
rengolin:desc
Open

Add PipelineDescriptor class#78
rengolin wants to merge 1 commit intollvm:mainfrom
rengolin:desc

Conversation

@rengolin
Copy link
Member

This allows creating an entire pipeline via YAML files. Supported stages are: pass, transform, bundle and include. Includes are relative to the original yaml file.

Bundles will be moved later, as they're still used by some examples. Migration of examples will come later, too, once we're happy with the design.

See: https://github.com/llvm/lighthouse/wiki/Pipeline

This allows creating an entire pipeline via YAML files. Supported stages are: pass, transform, bundle and include. Includes are relative to the original yaml file.

Bundles will be moved later, as they're still used by some examples. Migration of examples will come later, too, once we're happy with the design.

See: https://github.com/llvm/lighthouse/wiki/Pipeline
Comment on lines +13 to +18
Pipeline:
- pass: PassName
- transform: TransformFile.mlir
- include: OtherPipeline.yaml
- bundle: BundleName
...
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What about allowing arrays/list rather than just single entries? This could be very handy for yaml files whichi define a traditional pipeline, generally more than of the same kind in a sequence.

Copy link
Member Author

@rengolin rengolin Mar 16, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A list is just a sub-pipeline, imported via include. Recursive even.

While a short list would look ok:

  - pass: cse,canonicalize

a longer list would look better as multiple entries:

  - pass: "one-shot-bufferize{function-boundary-type-conversion=identity-layout-map bufferize-function-boundaries},drop-equivalent-buffer-results,buffer-deallocation-pipeline"

vs.

  - pass: one-shot-bufferize{function-boundary-type-conversion=identity-layout-map bufferize-function-boundaries}
  - pass: drop-equivalent-buffer-results
  - pass: buffer-deallocation-pipeline

Also, a list would need to allow different types (pass/transform/yaml/bundle) which would look even weirder (especially if one of the items is an include).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants