softgpu 0.8.0

Developer-oriented GPU emulation, testing, debugging, and sanitization runtime
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
/* SoftGPU Phase 6 host reference for tiny_add.
 *
 * Provenance path (disclosed):
 *   this C reference → hand-translated softgpu-sfir-v1 (see tiny_add.sfir.json
 *   and softgpu_functional::kernels::tiny_add).
 *
 * SoftGPU does NOT claim this was recovered from an AMDGPU code object.
 */
#include <stdint.h>
#include <stddef.h>

void tiny_add_host(const int32_t *a, int32_t *b, size_t n) {
  for (size_t i = 0; i < n; i++) {
    b[i] = a[i] + 1;
  }
}