Interplane page as plain text, for reading tools and agents. English is the reference text: translate it with your own tool. Text in backticks and in ``` blocks (commands, fingerprints, file names) and link targets in <...> are exact: copy them, never translate them. Page: /drakestapleton/CUDApp/blob/main/om/numeric/reduce.om # CUDApp CUDA++: AIEN’s GPU machine-code toolchain, runtime and driver client for NVIDIA GPUs without the CUDA toolkit. Hardware coverage and driver replacement limits are explicit. Brought by drakestapleton Sign in to star 0 stars 0 watching About Files History Releases Proposed changes Issues For developers branch `main` Branches Tags History `CUDApp / om / numeric / reduce.om` 20 lines · 407 bytes Raw Blame History 1 note SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception 2 note One padded hierarchy stage, or explicitly non-contract left fold. 3 fn numeric_reduce op ulong n ulong t view ulong 32 seq ulong init ulong to ulong 4 v = new ulong 32 0 5 if eq seq 1 6 r = init 7 for i ulong n 8 r = fadd32 r get t i 9 end 10 ret r 11 end 12 for i ulong 32 13 x = nrreduce 0 op 0 0 0 14 if lt i n 15 x = get t i 16 end 17 put v i x 18 end 19 ret numeric_tile op v 20 end