Back to PBT run
input.mlir
dataflow.thread private @thread_0 domain(#dataflow.thread_domain<dense>)(%buf: memref<8xi32>) ctrl (%thread_ctrl: none) {
%value = arith.constant 7 : i32
scf.forall (%lane) in (4) {
memref.store %value, %buf[%lane] : memref<8xi32>
}
dataflow.thread.yield %thread_ctrl : none
}
func.func @host_0() {
%buf = memref.alloc() : memref<8xi32>
%token = dataflow.thread.launch @thread_0(%buf) : (memref<8xi32>) -> !dataflow.thread_token
return
}
dataflow.thread private @thread_1 domain(#dataflow.thread_domain<dense>)(%buf: memref<8xi32>) ctrl (%thread_ctrl: none) iv (%coord_0: index) {
%value = arith.constant 7 : i32
dataflow.thread.yield %thread_ctrl : none
}
func.func @host_1() {
%buf = memref.alloc() : memref<8xi32>
%g0 = arith.constant 4 : index
%token = dataflow.thread.launch @thread_1(%buf) grid(%g0) : (memref<8xi32>) -> !dataflow.thread_token
return
}
dataflow.thread private @thread_2 domain(#dataflow.thread_domain<dense>)(%buf: memref<8xi32>) ctrl (%thread_ctrl: none) iv (%coord_0: index) {
%value = arith.constant 7 : i32
scf.forall (%lane) in (8) {
memref.store %value, %buf[%lane] : memref<8xi32>
}
dataflow.thread.yield
}
func.func @host_2() {
%buf = memref.alloc() : memref<8xi32>
%g0 = arith.constant 4 : index
%token = dataflow.thread.launch @thread_2(%buf) grid(%g0) : (memref<8xi32>) -> !dataflow.thread_token
return
}