| 214 | } |
| 215 | )"; |
| 216 | void puzzle6(Context &ctx) { |
| 217 | printf("\n\nPuzzle 6\n\n"); |
| 218 | static constexpr size_t N = 9; |
| 219 | static constexpr size_t Wx = 4; |
| 220 | static constexpr size_t Bx = 3; |
| 221 | Tensor a = createTensor(ctx, {N}, kf32, makeData<N>().data()); |
| 222 | Tensor output = createTensor(ctx, {N}, kf32); |
| 223 | struct Params { |
| 224 | uint32_t size = N; |
| 225 | }; |
| 226 | |
| 227 | Kernel op = |
| 228 | createKernel(ctx, {kPuzzle6, {Wx, 1, 1}}, |
| 229 | Bindings{a, output}, {Bx, 1, 1}, Params{N}); |
| 230 | showResult<N>(ctx, op, output); |
| 231 | } |
| 232 | |
| 233 | // Puzzle 7 : Blocks 2D |
| 234 | // Implement the same kernel in 2D. |
no test coverage detected