@@ -13,6 +13,61 @@ import ...IR:
1313import .. Dialects: namedattribute, operandsegmentsizes
1414import ... API
1515
16+ function get_stream (; result:: IR.Type , location= Location ())
17+ op_ty_results = IR. Type[result,]
18+ operands = Value[]
19+ owned_regions = Region[]
20+ successors = Block[]
21+ attributes = NamedAttribute[]
22+
23+ return create_operation (
24+ " enzymexla.get_stream" ,
25+ location;
26+ operands,
27+ owned_regions,
28+ successors,
29+ attributes,
30+ results= op_ty_results,
31+ result_inference= false ,
32+ )
33+ end
34+
35+ function jit_call (
36+ inputs:: Vector{Value} ;
37+ result_0:: Vector{IR.Type} ,
38+ fn,
39+ backend_config= nothing ,
40+ operand_layouts= nothing ,
41+ result_layouts= nothing ,
42+ output_operand_aliases= nothing ,
43+ location= Location (),
44+ )
45+ op_ty_results = IR. Type[result_0... ,]
46+ operands = Value[inputs... ,]
47+ owned_regions = Region[]
48+ successors = Block[]
49+ attributes = NamedAttribute[namedattribute (" fn" , fn),]
50+ ! isnothing (backend_config) &&
51+ push! (attributes, namedattribute (" backend_config" , backend_config))
52+ ! isnothing (operand_layouts) &&
53+ push! (attributes, namedattribute (" operand_layouts" , operand_layouts))
54+ ! isnothing (result_layouts) &&
55+ push! (attributes, namedattribute (" result_layouts" , result_layouts))
56+ ! isnothing (output_operand_aliases) &&
57+ push! (attributes, namedattribute (" output_operand_aliases" , output_operand_aliases))
58+
59+ return create_operation (
60+ " enzymexla.jit_call" ,
61+ location;
62+ operands,
63+ owned_regions,
64+ successors,
65+ attributes,
66+ results= op_ty_results,
67+ result_inference= false ,
68+ )
69+ end
70+
1671function kernel_call (
1772 gridx:: Value ,
1873 gridy:: Value ,
0 commit comments