def tree2

bend-ml-tensor-gpu@0.1.5.1 · main.bend:439

import bend-ml-tensor-gpu@0.1.5.1/main.bend as BendMlTensorGpu
import Base

439def tree2(~E: Data, ~f: @+t: U32 -> @+l: U32 -> @+e: E -> Array<F32> -> Array<F32> -> Array<F32> -> Array<F32> -> O2 -> O2, +d: Nat, +t: U32, +l: U32, +e: E, +x1: Array<F32>, +x2: Array<F32>, +x3: Array<F32>, +x4: Array<F32>, +oa: Array<F32>, +ob: Array<F32>) -> O2:
440  match d:
441    case 0n: f(t, l, e, x1, x2, x3, x4, O2{oa, ob})
442    case 1n+q:
443      x y = tree2(~E, ~f, q, (t * 2 : U32), l, e, x1, x2, x3, x4, oa, ob) tree2(~E, ~f, q, ((t * 2 : U32) + 1 : U32), l, e, x1, x2, x3, x4, oa, ob)
444      join2(x, y)
445
446@unsafe

Uses (8)

Used by (1)