File tree Expand file tree Collapse file tree 2 files changed +19
-1
lines changed Expand file tree Collapse file tree 2 files changed +19
-1
lines changed Original file line number Diff line number Diff line change @@ -118,7 +118,8 @@ void call_interface_impl::printFunctionSignature(
118
118
ArrayRef<NamedAttribute> attrs;
119
119
if (argAttrs)
120
120
attrs = llvm::cast<DictionaryAttr>(argAttrs[i]).getValue ();
121
- p.printRegionArgument (body->getArgument (i), attrs);
121
+ if (body->getNumArguments () > i)
122
+ p.printRegionArgument (body->getArgument (i), attrs);
122
123
} else {
123
124
p.printType (argTypes[i]);
124
125
if (argAttrs)
Original file line number Diff line number Diff line change
1
+ // Bug: https://github.com/llvm/llvm-project/issues/132894
2
+
3
+ // RUN: mlir-opt %s | FileCheck
4
+
5
+ // CHECK: module {
6
+ // CHECK: spirv.func @f(f32) "None" {
7
+ // CHECK: %c0 = arith.constant 0 : index
8
+ // CHECK: spirv.Return
9
+ // CHECK: }
10
+ // CHECK: }
11
+
12
+ module {
13
+ spirv.func @f (f32 ) " None" {
14
+ %c0 = arith.constant 0 : index
15
+ spirv.Return
16
+ }
17
+ }
You can’t perform that action at this time.
0 commit comments