1302 lines · plain
1================================================================================2func.func with result attribute3================================================================================4func.func @example_fn_result() -> (f64 {dialectName.attrName = 0 : i64})5--------------------------------------------------------------------------------6 7(toplevel8 (operation9 (custom_operation10 (func_dialect11 (symbol_ref_id)12 (func_arg_list)13 (func_return14 (type_list_attr_parens15 (type16 (builtin_type17 (float_type)))18 (attribute19 (dictionary_attribute20 (attribute_entry21 (bare_id)22 (attribute_value23 (integer_literal)24 (type25 (builtin_type26 (integer_type)))))))))))))27 28================================================================================29func.func with argument attribute30================================================================================31func.func @example_fn_arg(%x: i32 {swift.self = unit})32--------------------------------------------------------------------------------33 34(toplevel35 (operation36 (custom_operation37 (func_dialect38 (symbol_ref_id)39 (func_arg_list40 (value_use)41 (type42 (builtin_type43 (integer_type)))44 (attribute45 (dictionary_attribute46 (attribute_entry47 (bare_id)48 (attribute_value49 (unit_literal))))))))))50 51================================================================================52strided attribute in memref53================================================================================54func.func @dot_view(%arg0: memref<?xf32, strided<[1], offset: ?>>,55 %arg1: memref<?xf32, strided<[1], offset: ?>>, %arg2: memref<f32>) {56 linalg.dot ins(%arg0, %arg1 : memref<?xf32, strided<[1], offset: ?>>,57 memref<?xf32, strided<[1], offset: ?>>)58 outs(%arg2: memref<f32>)59 return60}61--------------------------------------------------------------------------------62 63(toplevel64 (operation65 (custom_operation66 (func_dialect67 (symbol_ref_id)68 (func_arg_list69 (value_use)70 (type71 (builtin_type72 (memref_type73 (dim_list74 (float_type))75 (attribute_value76 (builtin_attribute77 (strided_layout))))))78 (value_use)79 (type80 (builtin_type81 (memref_type82 (dim_list83 (float_type))84 (attribute_value85 (builtin_attribute86 (strided_layout))))))87 (value_use)88 (type89 (builtin_type90 (memref_type91 (dim_list92 (float_type))))))93 (region94 (entry_block95 (operation96 (custom_operation97 (linalg_dialect98 (value_use)99 (value_use)100 (type101 (builtin_type102 (memref_type103 (dim_list104 (float_type))105 (attribute_value106 (builtin_attribute107 (strided_layout))))))108 (type109 (builtin_type110 (memref_type111 (dim_list112 (float_type))113 (attribute_value114 (builtin_attribute115 (strided_layout))))))116 (value_use)117 (type118 (builtin_type119 (memref_type120 (dim_list121 (float_type))))))))122 (operation123 (custom_operation124 (func_dialect)))))))))125 126================================================================================127dense attribute in linalg.depthwise_conv_1d_nwc_wcm128================================================================================129func.func @depthwise_conv_1d_nwc_wcm(%input: tensor<1x12x8xf32>, %filter: tensor<3x8x8xf32>)130 -> tensor<1x10x8x8xf32> {131 %zero = arith.constant 0.000000e+00 : f32132 %init = tensor.empty() : tensor<1x10x8x8xf32>133 %fill = linalg.fill ins(%zero : f32) outs(%init : tensor<1x10x8x8xf32>) -> tensor<1x10x8x8xf32>134 %0 = linalg.depthwise_conv_1d_nwc_wcm {dilations = dense<1> : tensor<1xi64>,135 strides = dense<1> : tensor<1xi64>}136 ins(%input, %filter : tensor<1x12x8xf32>, tensor<3x8x8xf32>)137 outs(%fill : tensor<1x10x8x8xf32>) -> tensor<1x10x8x8xf32>138 return %0 : tensor<1x10x8x8xf32>139}140--------------------------------------------------------------------------------141 142(toplevel143 (operation144 (custom_operation145 (func_dialect146 (symbol_ref_id)147 (func_arg_list148 (value_use)149 (type150 (builtin_type151 (tensor_type152 (dim_list153 (float_type)))))154 (value_use)155 (type156 (builtin_type157 (tensor_type158 (dim_list159 (float_type))))))160 (func_return161 (type_list_attr_parens162 (type163 (builtin_type164 (tensor_type165 (dim_list166 (float_type)))))))167 (region168 (entry_block169 (operation170 (op_result171 (value_use))172 (custom_operation173 (arith_dialect174 (float_literal)175 (type176 (builtin_type177 (float_type))))))178 (operation179 (op_result180 (value_use))181 (custom_operation182 (tensor_dialect183 (type184 (builtin_type185 (tensor_type186 (dim_list187 (float_type))))))))188 (operation189 (op_result190 (value_use))191 (custom_operation192 (linalg_dialect193 (value_use)194 (type195 (builtin_type196 (float_type)))197 (value_use)198 (type199 (builtin_type200 (tensor_type201 (dim_list202 (float_type)))))203 (type204 (builtin_type205 (tensor_type206 (dim_list207 (float_type))))))))208 (operation209 (op_result210 (value_use))211 (custom_operation212 (linalg_dialect213 (attribute214 (dictionary_attribute215 (attribute_entry216 (bare_id)217 (attribute_value218 (tensor_literal219 (integer_literal))220 (type221 (builtin_type222 (tensor_type223 (dim_list224 (integer_type)))))))225 (attribute_entry226 (bare_id)227 (attribute_value228 (tensor_literal229 (integer_literal))230 (type231 (builtin_type232 (tensor_type233 (dim_list234 (integer_type)))))))))235 (value_use)236 (value_use)237 (type238 (builtin_type239 (tensor_type240 (dim_list241 (float_type)))))242 (type243 (builtin_type244 (tensor_type245 (dim_list246 (float_type)))))247 (value_use)248 (type249 (builtin_type250 (tensor_type251 (dim_list252 (float_type)))))253 (type254 (builtin_type255 (tensor_type256 (dim_list257 (float_type))))))))258 (operation259 (custom_operation260 (func_dialect261 (value_use)262 (type263 (builtin_type264 (tensor_type265 (dim_list266 (float_type))))))))))))))267 268================================================================================269fastmath attribute in arith270================================================================================271func.func @fastmath(%arg0: f32, %arg1: f32, %arg2: i32) {272 %0 = arith.addf %arg0, %arg1 fastmath<fast> : f32273 %1 = arith.subf %arg0, %arg1 fastmath<fast> : f32274 %2 = arith.mulf %arg0, %arg1 fastmath<fast> : f32275 %3 = arith.divf %arg0, %arg1 fastmath<fast> : f32276 %4 = arith.remf %arg0, %arg1 fastmath<fast> : f32277 %5 = arith.negf %arg0 fastmath<fast> : f32278 %6 = arith.addf %arg0, %arg1 fastmath<none> : f32279 %7 = arith.addf %arg0, %arg1 fastmath<nnan,ninf> : f32280 %8 = arith.mulf %arg0, %arg1 fastmath<reassoc,nnan,ninf,nsz,arcp,contract,afn> : f32281 return282}283--------------------------------------------------------------------------------284 285(toplevel286 (operation287 (custom_operation288 (func_dialect289 (symbol_ref_id)290 (func_arg_list291 (value_use)292 (type293 (builtin_type294 (float_type)))295 (value_use)296 (type297 (builtin_type298 (float_type)))299 (value_use)300 (type301 (builtin_type302 (integer_type))))303 (region304 (entry_block305 (operation306 (op_result307 (value_use))308 (custom_operation309 (arith_dialect310 (value_use)311 (value_use)312 (fastmath_attr)313 (type314 (builtin_type315 (float_type))))))316 (operation317 (op_result318 (value_use))319 (custom_operation320 (arith_dialect321 (value_use)322 (value_use)323 (fastmath_attr)324 (type325 (builtin_type326 (float_type))))))327 (operation328 (op_result329 (value_use))330 (custom_operation331 (arith_dialect332 (value_use)333 (value_use)334 (fastmath_attr)335 (type336 (builtin_type337 (float_type))))))338 (operation339 (op_result340 (value_use))341 (custom_operation342 (arith_dialect343 (value_use)344 (value_use)345 (fastmath_attr)346 (type347 (builtin_type348 (float_type))))))349 (operation350 (op_result351 (value_use))352 (custom_operation353 (arith_dialect354 (value_use)355 (value_use)356 (fastmath_attr)357 (type358 (builtin_type359 (float_type))))))360 (operation361 (op_result362 (value_use))363 (custom_operation364 (arith_dialect365 (value_use)366 (fastmath_attr)367 (type368 (builtin_type369 (float_type))))))370 (operation371 (op_result372 (value_use))373 (custom_operation374 (arith_dialect375 (value_use)376 (value_use)377 (fastmath_attr)378 (type379 (builtin_type380 (float_type))))))381 (operation382 (op_result383 (value_use))384 (custom_operation385 (arith_dialect386 (value_use)387 (value_use)388 (fastmath_attr)389 (type390 (builtin_type391 (float_type))))))392 (operation393 (op_result394 (value_use))395 (custom_operation396 (arith_dialect397 (value_use)398 (value_use)399 (fastmath_attr)400 (type401 (builtin_type402 (float_type))))))403 (operation404 (custom_operation405 (func_dialect)))))))))406 407================================================================================408Generic function bracketed attributes409================================================================================410"llvm.func"() ({411}) {sym_name = "qux", function_type = !llvm.func<void (ptr<i64>, i64)>,412 arg_attrs = [{llvm.noalias}, {}], xxx = {yyy = 42}} : () -> ()413--------------------------------------------------------------------------------414 415(toplevel416 (operation417 (generic_operation418 (string_literal)419 (region)420 (attribute421 (dictionary_attribute422 (attribute_entry423 (bare_id)424 (attribute_value425 (string_literal)))426 (attribute_entry427 (bare_id)428 (attribute_value429 (type430 (dialect_type431 (pretty_dialect_item432 (dialect_namespace)433 (dialect_ident)434 (pretty_dialect_item_body435 (pretty_dialect_item_body)))))))436 (attribute_entry437 (bare_id)438 (attribute_value439 (dictionary_attribute440 (attribute_entry441 (bare_id)))442 (dictionary_attribute)))443 (attribute_entry444 (bare_id)445 (attribute_value446 (dictionary_attribute447 (attribute_entry448 (bare_id)449 (attribute_value450 (integer_literal))))))))451 (function_type))))452 453================================================================================454linalg.generic with attributes using attribute aliases455================================================================================456#map0 = affine_map<(d0, d1) -> (d0, d1)>457#map1 = affine_map<(d0, d1) -> (d0)>458#map2 = affine_map<(d0) -> (d0)>459 460func.func @add_broadcast_mul_fusion(%arg0: tensor<?xf32>, %arg1 : tensor<?xf32>,461 %arg2 : tensor<?x?xf32>) -> tensor<?x?xf32>462{463 %c0 = arith.constant 0 : index464 %c1 = arith.constant 1 : index465 %0 = tensor.dim %arg0, %c0 : tensor<?xf32>466 %1 = tensor.empty(%0) : tensor<?xf32>467 %2 = linalg.generic {indexing_maps = [#map2, #map2, #map2], iterator_types = ["parallel"]}468 ins(%arg0, %arg1 : tensor<?xf32>, tensor<?xf32>)469 outs(%1 : tensor<?xf32>) {470 ^bb0(%arg3: f32, %arg4: f32, %arg5: f32):471 %3 = arith.addf %arg3, %arg4 : f32472 linalg.yield %3 : f32473 } -> tensor<?xf32>474 %3 = tensor.dim %arg2, %c1 : tensor<?x?xf32>475 %4 = tensor.empty(%0, %3) : tensor<?x?xf32>476 %5 = linalg.generic {indexing_maps = [#map1, #map0, #map0], iterator_types = ["parallel", "parallel"]}477 ins(%2, %arg2 : tensor<?xf32>, tensor<?x?xf32>)478 outs(%4 : tensor<?x?xf32>){479 ^bb0(%arg5: f32, %arg6: f32, %arg7: f32):480 %6 = arith.mulf %arg5, %arg6 : f32481 linalg.yield %6 : f32482 } -> tensor<?x?xf32>483 return %5 : tensor<?x?xf32>484}485--------------------------------------------------------------------------------486 487(toplevel488 (attribute_alias_def489 (attribute_value490 (builtin_attribute491 (affine_map492 (bare_id)493 (bare_id)494 (bare_id)495 (bare_id)))))496 (attribute_alias_def497 (attribute_value498 (builtin_attribute499 (affine_map500 (bare_id)501 (bare_id)502 (bare_id)))))503 (attribute_alias_def504 (attribute_value505 (builtin_attribute506 (affine_map507 (bare_id)508 (bare_id)))))509 (operation510 (custom_operation511 (func_dialect512 (symbol_ref_id)513 (func_arg_list514 (value_use)515 (type516 (builtin_type517 (tensor_type518 (dim_list519 (float_type)))))520 (value_use)521 (type522 (builtin_type523 (tensor_type524 (dim_list525 (float_type)))))526 (value_use)527 (type528 (builtin_type529 (tensor_type530 (dim_list531 (float_type))))))532 (func_return533 (type_list_attr_parens534 (type535 (builtin_type536 (tensor_type537 (dim_list538 (float_type)))))))539 (region540 (entry_block541 (operation542 (op_result543 (value_use))544 (custom_operation545 (arith_dialect546 (integer_literal)547 (type548 (builtin_type549 (index_type))))))550 (operation551 (op_result552 (value_use))553 (custom_operation554 (arith_dialect555 (integer_literal)556 (type557 (builtin_type558 (index_type))))))559 (operation560 (op_result561 (value_use))562 (custom_operation563 (tensor_dialect564 (value_use)565 (value_use)566 (type567 (builtin_type568 (tensor_type569 (dim_list570 (float_type))))))))571 (operation572 (op_result573 (value_use))574 (custom_operation575 (tensor_dialect576 (value_use)577 (type578 (builtin_type579 (tensor_type580 (dim_list581 (float_type))))))))582 (operation583 (op_result584 (value_use))585 (custom_operation586 (linalg_dialect587 (attribute588 (dictionary_attribute589 (attribute_entry590 (bare_id)591 (attribute_value592 (attribute_alias)593 (attribute_alias)594 (attribute_alias)))595 (attribute_entry596 (bare_id)597 (attribute_value598 (string_literal)))))599 (value_use)600 (value_use)601 (type602 (builtin_type603 (tensor_type604 (dim_list605 (float_type)))))606 (type607 (builtin_type608 (tensor_type609 (dim_list610 (float_type)))))611 (value_use)612 (type613 (builtin_type614 (tensor_type615 (dim_list616 (float_type)))))617 (region618 (block619 (block_label620 (caret_id)621 (block_arg_list622 (value_use)623 (type624 (builtin_type625 (float_type)))626 (value_use)627 (type628 (builtin_type629 (float_type)))630 (value_use)631 (type632 (builtin_type633 (float_type)))))634 (operation635 (op_result636 (value_use))637 (custom_operation638 (arith_dialect639 (value_use)640 (value_use)641 (type642 (builtin_type643 (float_type))))))644 (operation645 (custom_operation646 (linalg_dialect647 (value_use)648 (type649 (builtin_type650 (float_type))))))))651 (type652 (builtin_type653 (tensor_type654 (dim_list655 (float_type))))))))656 (operation657 (op_result658 (value_use))659 (custom_operation660 (tensor_dialect661 (value_use)662 (value_use)663 (type664 (builtin_type665 (tensor_type666 (dim_list667 (float_type))))))))668 (operation669 (op_result670 (value_use))671 (custom_operation672 (tensor_dialect673 (value_use)674 (value_use)675 (type676 (builtin_type677 (tensor_type678 (dim_list679 (float_type))))))))680 (operation681 (op_result682 (value_use))683 (custom_operation684 (linalg_dialect685 (attribute686 (dictionary_attribute687 (attribute_entry688 (bare_id)689 (attribute_value690 (attribute_alias)691 (attribute_alias)692 (attribute_alias)))693 (attribute_entry694 (bare_id)695 (attribute_value696 (string_literal)697 (string_literal)))))698 (value_use)699 (value_use)700 (type701 (builtin_type702 (tensor_type703 (dim_list704 (float_type)))))705 (type706 (builtin_type707 (tensor_type708 (dim_list709 (float_type)))))710 (value_use)711 (type712 (builtin_type713 (tensor_type714 (dim_list715 (float_type)))))716 (region717 (block718 (block_label719 (caret_id)720 (block_arg_list721 (value_use)722 (type723 (builtin_type724 (float_type)))725 (value_use)726 (type727 (builtin_type728 (float_type)))729 (value_use)730 (type731 (builtin_type732 (float_type)))))733 (operation734 (op_result735 (value_use))736 (custom_operation737 (arith_dialect738 (value_use)739 (value_use)740 (type741 (builtin_type742 (float_type))))))743 (operation744 (custom_operation745 (linalg_dialect746 (value_use)747 (type748 (builtin_type749 (float_type))))))))750 (type751 (builtin_type752 (tensor_type753 (dim_list754 (float_type))))))))755 (operation756 (custom_operation757 (func_dialect758 (value_use)759 (type760 (builtin_type761 (tensor_type762 (dim_list763 (float_type))))))))))))))764 765================================================================================766linalg.generic with attribute alias767================================================================================768#map0 = affine_map<() -> ()>769 770#attrs = {771 indexing_maps = [#map0, #map0, #map0],772 iterator_types = []773}774 775func.func @main() -> (tensor<i32>) attributes {} {776 %c0 = arith.constant 0 : i32777 %0 = tensor.from_elements %c0 : tensor<i32>778 %c10 = arith.constant 10 : i32779 %1 = tensor.from_elements %c10 : tensor<i32>780 cf.br ^bb1(%0 : tensor<i32>)781 782^bb1(%2: tensor<i32>): // 2 preds: ^bb0, ^bb2783 %3 = tensor.empty() : tensor<i1>784 %4 = linalg.generic #attrs785 ins(%2, %1 : tensor<i32>, tensor<i32>)786 outs(%3 : tensor<i1>) {787 ^bb0(%arg0: i32, %arg1: i32, %arg2: i1):788 %8 = arith.cmpi slt, %arg0, %arg1 : i32789 linalg.yield %8 : i1790 } -> tensor<i1>791 %5 = tensor.extract %4[] : tensor<i1>792 cf.cond_br %5, ^bb2(%2 : tensor<i32>), ^bb3(%2 : tensor<i32>)793 794^bb2(%6: tensor<i32>): // pred: ^bb1795 %7 = tensor.empty() : tensor<i32>796 %8 = linalg.generic #attrs797 ins(%6, %6 : tensor<i32>, tensor<i32>)798 outs(%7 : tensor<i32>) {799 ^bb0(%arg0: i32, %arg1: i32, %arg2: i32):800 %9 = arith.addi %arg0, %arg1 : i32801 linalg.yield %9 : i32802 } -> tensor<i32>803 cf.br ^bb3(%8 : tensor<i32>)804 805^bb3(%10: tensor<i32>): // pred: ^bb1806 return %10 : tensor<i32>807}808--------------------------------------------------------------------------------809 810(toplevel811 (attribute_alias_def812 (attribute_value813 (builtin_attribute814 (affine_map))))815 (attribute_alias_def816 (attribute_value817 (dictionary_attribute818 (attribute_entry819 (bare_id)820 (attribute_value821 (attribute_alias)822 (attribute_alias)823 (attribute_alias)))824 (attribute_entry825 (bare_id)826 (attribute_value)))))827 (operation828 (custom_operation829 (func_dialect830 (symbol_ref_id)831 (func_arg_list)832 (func_return833 (type_list_attr_parens834 (type835 (builtin_type836 (tensor_type837 (dim_list838 (integer_type)))))))839 (attribute840 (dictionary_attribute))841 (region842 (entry_block843 (operation844 (op_result845 (value_use))846 (custom_operation847 (arith_dialect848 (integer_literal)849 (type850 (builtin_type851 (integer_type))))))852 (operation853 (op_result854 (value_use))855 (custom_operation856 (tensor_dialect857 (value_use)858 (type859 (builtin_type860 (tensor_type861 (dim_list862 (integer_type))))))))863 (operation864 (op_result865 (value_use))866 (custom_operation867 (arith_dialect868 (integer_literal)869 (type870 (builtin_type871 (integer_type))))))872 (operation873 (op_result874 (value_use))875 (custom_operation876 (tensor_dialect877 (value_use)878 (type879 (builtin_type880 (tensor_type881 (dim_list882 (integer_type))))))))883 (operation884 (custom_operation885 (cf_dialect886 (successor887 (caret_id)888 (value_use)889 (type890 (builtin_type891 (tensor_type892 (dim_list893 (integer_type))))))))))894 (block895 (block_label896 (caret_id)897 (block_arg_list898 (value_use)899 (type900 (builtin_type901 (tensor_type902 (dim_list903 (integer_type)))))))904 (comment)905 (operation906 (op_result907 (value_use))908 (custom_operation909 (tensor_dialect910 (type911 (builtin_type912 (tensor_type913 (dim_list914 (integer_type))))))))915 (operation916 (op_result917 (value_use))918 (custom_operation919 (linalg_dialect920 (attribute921 (attribute_alias))922 (value_use)923 (value_use)924 (type925 (builtin_type926 (tensor_type927 (dim_list928 (integer_type)))))929 (type930 (builtin_type931 (tensor_type932 (dim_list933 (integer_type)))))934 (value_use)935 (type936 (builtin_type937 (tensor_type938 (dim_list939 (integer_type)))))940 (region941 (block942 (block_label943 (caret_id)944 (block_arg_list945 (value_use)946 (type947 (builtin_type948 (integer_type)))949 (value_use)950 (type951 (builtin_type952 (integer_type)))953 (value_use)954 (type955 (builtin_type956 (integer_type)))))957 (operation958 (op_result959 (value_use))960 (custom_operation961 (arith_dialect962 (value_use)963 (value_use)964 (type965 (builtin_type966 (integer_type))))))967 (operation968 (custom_operation969 (linalg_dialect970 (value_use)971 (type972 (builtin_type973 (integer_type))))))))974 (type975 (builtin_type976 (tensor_type977 (dim_list978 (integer_type))))))))979 (operation980 (op_result981 (value_use))982 (custom_operation983 (tensor_dialect984 (value_use)985 (type986 (builtin_type987 (tensor_type988 (dim_list989 (integer_type))))))))990 (operation991 (custom_operation992 (cf_dialect993 (value_use)994 (successor995 (caret_id)996 (value_use)997 (type998 (builtin_type999 (tensor_type1000 (dim_list1001 (integer_type))))))1002 (successor1003 (caret_id)1004 (value_use)1005 (type1006 (builtin_type1007 (tensor_type1008 (dim_list1009 (integer_type))))))))))1010 (block1011 (block_label1012 (caret_id)1013 (block_arg_list1014 (value_use)1015 (type1016 (builtin_type1017 (tensor_type1018 (dim_list1019 (integer_type)))))))1020 (comment)1021 (operation1022 (op_result1023 (value_use))1024 (custom_operation1025 (tensor_dialect1026 (type1027 (builtin_type1028 (tensor_type1029 (dim_list1030 (integer_type))))))))1031 (operation1032 (op_result1033 (value_use))1034 (custom_operation1035 (linalg_dialect1036 (attribute1037 (attribute_alias))1038 (value_use)1039 (value_use)1040 (type1041 (builtin_type1042 (tensor_type1043 (dim_list1044 (integer_type)))))1045 (type1046 (builtin_type1047 (tensor_type1048 (dim_list1049 (integer_type)))))1050 (value_use)1051 (type1052 (builtin_type1053 (tensor_type1054 (dim_list1055 (integer_type)))))1056 (region1057 (block1058 (block_label1059 (caret_id)1060 (block_arg_list1061 (value_use)1062 (type1063 (builtin_type1064 (integer_type)))1065 (value_use)1066 (type1067 (builtin_type1068 (integer_type)))1069 (value_use)1070 (type1071 (builtin_type1072 (integer_type)))))1073 (operation1074 (op_result1075 (value_use))1076 (custom_operation1077 (arith_dialect1078 (value_use)1079 (value_use)1080 (type1081 (builtin_type1082 (integer_type))))))1083 (operation1084 (custom_operation1085 (linalg_dialect1086 (value_use)1087 (type1088 (builtin_type1089 (integer_type))))))))1090 (type1091 (builtin_type1092 (tensor_type1093 (dim_list1094 (integer_type))))))))1095 (operation1096 (custom_operation1097 (cf_dialect1098 (successor1099 (caret_id)1100 (value_use)1101 (type1102 (builtin_type1103 (tensor_type1104 (dim_list1105 (integer_type))))))))))1106 (block1107 (block_label1108 (caret_id)1109 (block_arg_list1110 (value_use)1111 (type1112 (builtin_type1113 (tensor_type1114 (dim_list1115 (integer_type)))))))1116 (comment)1117 (operation1118 (custom_operation1119 (func_dialect1120 (value_use)1121 (type1122 (builtin_type1123 (tensor_type1124 (dim_list1125 (integer_type))))))))))))))1126 1127================================================================================1128linalg.generic with inline attributes1129================================================================================1130func.func @copy_view(%arg0: memref<?xf32, strided<[1], offset: ?>>,1131 %arg1: memref<?xf32, strided<[1], offset: ?>>) {1132 linalg.generic {1133 iterator_types = ["parallel"],1134 indexing_maps = [ affine_map<(i) -> (i)>, affine_map<(i) -> (i)>] }1135 ins(%arg0: memref<?xf32, strided<[1], offset: ?>>)1136 outs(%arg1: memref<?xf32, strided<[1], offset: ?>>) {1137 ^bb0(%a: f32, %b: f32):1138 linalg.yield %a : f321139 }1140 return1141}1142--------------------------------------------------------------------------------1143 1144(toplevel1145 (operation1146 (custom_operation1147 (func_dialect1148 (symbol_ref_id)1149 (func_arg_list1150 (value_use)1151 (type1152 (builtin_type1153 (memref_type1154 (dim_list1155 (float_type))1156 (attribute_value1157 (builtin_attribute1158 (strided_layout))))))1159 (value_use)1160 (type1161 (builtin_type1162 (memref_type1163 (dim_list1164 (float_type))1165 (attribute_value1166 (builtin_attribute1167 (strided_layout)))))))1168 (region1169 (entry_block1170 (operation1171 (custom_operation1172 (linalg_dialect1173 (attribute1174 (dictionary_attribute1175 (attribute_entry1176 (bare_id)1177 (attribute_value1178 (string_literal)))1179 (attribute_entry1180 (bare_id)1181 (attribute_value1182 (builtin_attribute1183 (affine_map1184 (bare_id)1185 (bare_id)))1186 (builtin_attribute1187 (affine_map1188 (bare_id)1189 (bare_id)))))))1190 (value_use)1191 (type1192 (builtin_type1193 (memref_type1194 (dim_list1195 (float_type))1196 (attribute_value1197 (builtin_attribute1198 (strided_layout))))))1199 (value_use)1200 (type1201 (builtin_type1202 (memref_type1203 (dim_list1204 (float_type))1205 (attribute_value1206 (builtin_attribute1207 (strided_layout))))))1208 (region1209 (block1210 (block_label1211 (caret_id)1212 (block_arg_list1213 (value_use)1214 (type1215 (builtin_type1216 (float_type)))1217 (value_use)1218 (type1219 (builtin_type1220 (float_type)))))1221 (operation1222 (custom_operation1223 (linalg_dialect1224 (value_use)1225 (type1226 (builtin_type1227 (float_type)))))))))))1228 (operation1229 (custom_operation1230 (func_dialect)))))))))1231 1232================================================================================1233linalg.broadcast with inline attributes, without dictionary tokens1234================================================================================1235func.func @broadcast(%input: tensor<8x32xf32>,1236 %init: tensor<8x16x32xf32>) -> tensor<8x16x32xf32> {1237 %bcast = linalg.broadcast1238 ins(%input:tensor<8x32xf32>)1239 outs(%init:tensor<8x16x32xf32>)1240 dimensions = [1]1241 func.return %bcast : tensor<8x16x32xf32>1242}1243--------------------------------------------------------------------------------1244 1245(toplevel1246 (operation1247 (custom_operation1248 (func_dialect1249 (symbol_ref_id)1250 (func_arg_list1251 (value_use)1252 (type1253 (builtin_type1254 (tensor_type1255 (dim_list1256 (float_type)))))1257 (value_use)1258 (type1259 (builtin_type1260 (tensor_type1261 (dim_list1262 (float_type))))))1263 (func_return1264 (type_list_attr_parens1265 (type1266 (builtin_type1267 (tensor_type1268 (dim_list1269 (float_type)))))))1270 (region1271 (entry_block1272 (operation1273 (op_result1274 (value_use))1275 (custom_operation1276 (linalg_dialect1277 (value_use)1278 (type1279 (builtin_type1280 (tensor_type1281 (dim_list1282 (float_type)))))1283 (value_use)1284 (type1285 (builtin_type1286 (tensor_type1287 (dim_list1288 (float_type)))))1289 (bare_attribute_entry1290 (bare_id)1291 (attribute_value1292 (integer_literal))))))1293 (operation1294 (custom_operation1295 (func_dialect1296 (value_use)1297 (type1298 (builtin_type1299 (tensor_type1300 (dim_list1301 (float_type))))))))))))))1302