interplane.Get Omega
Read in your language

openaccel-lab

aien-dev/openaccel-lab

Brought by drakestapleton

branch main Branches Tags History

openaccel-lab / workloads / saxpy / workload.json

28 lines · 1382 bytes Raw Blame History
1{
2 "name": "saxpy",
3 "family": "memory-bound",
4 "summary": "y[i] = alpha * x[i] + y_in[i] over n f32 elements; alpha is a one-element f32 input",
5 "provenance": "authored for OpenAccel Lab (Apache-2.0); BLAS level-1 SAXPY semantics",
6 "params": {"n": 100003},
7 "cases": [{}, {"n": 1}, {"n": 4099}],
8 "shrink": {"n": {"min": 1}},
9 "inputs": [
10 {"name": "alpha", "dtype": "f32", "shape": [1], "gen": {"kind": "uniform", "lo": -2.0, "hi": 2.0}},
11 {"name": "x", "dtype": "f32", "shape": ["n"], "gen": {"kind": "uniform", "lo": -4.0, "hi": 4.0}},
12 {"name": "y_in", "dtype": "f32", "shape": ["n"], "gen": {"kind": "normal4", "std": 2.0}}
13 ],
14 "outputs": [{"name": "y", "dtype": "f32", "shape": ["n"]}],
15 "tolerance": {
16 "y": {"kind": "bound", "rtol": "gamma(2)", "atol": 0,
17 "why": "alpha*x+y is a length-2 dot product (alpha,1).(x,y): unfused it is two roundings, fused one, so |err| <= gamma(2)*(|alpha x|+|y|) (Higham Thm 3.1); reference.py passes |alpha x|+|y| as scale. WolframLanguageEvaluator: g[n_]:=n 2^-24/(1-n 2^-24); N[g[2],6] -> 1.19209*10^-7"}
18 },
19 "timing": {"warmup": 2, "repeats": 10},
20 "backends": {
21 "omega": {"src": "omega.om"},
22 "opencl": {"src": "kernel.cl", "launches": [
23 {"kernel": "saxpy", "global": ["n"], "local": null, "args": ["alpha", "x", "y_in", "y", "n"]}
24 ]},
25 "triton": {"src": "triton_kernel.py"},
26 "cuda": {"src": "kernel.cu"}
27 }
28}