diff --git a/src/dialect/onnx/onnx.td b/src/dialect/onnx/onnx.td index 7396990..027af43 100644 --- a/src/dialect/onnx/onnx.td +++ b/src/dialect/onnx/onnx.td @@ -78,6 +78,17 @@ def ONNXEntryPointOp: ONNX_Op<"EntryPoint"> { }]; } +//===----------------------------------------------------------------------===// +// ONNX Operations for handling optional arguments +//===----------------------------------------------------------------------===// + +// To allow pattern matching on operations with optional arguments/outputs we +// implement variants of the original ONNX dialect operations. The ONNX +// operations automatically generated by the `gen_doc.py` script and included +// in the `onnxop.inc` file have all optional arguments and outputs present. +// In the operations below we include the variants with missing operands +// or outputs. This decision affects only ONNX operations with optional +// arguments not ONNX operations with variadic operands. def ONNXFullGemmOp: ONNX_Op<"FullGemm", [NoSideEffect, DeclareOpInterfaceMethods]> {