Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ module github.com/go-ndarray/go-ndarray.github.io

go 1.27.4

require github.com/go-fleettools/landingkit v0.21.0
require github.com/go-fleettools/landingkit v0.29.0
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
github.com/go-fleettools/landingkit v0.21.0 h1:fcg3aS5pTvzzR+ht/LcKY7SXeFW+6PMYvB7TODmzL1c=
github.com/go-fleettools/landingkit v0.21.0/go.mod h1:jSXTO7FVKNXCK1aJjLq7H7x8d8wxDoXe3ncXWGcAKRE=
github.com/go-fleettools/landingkit v0.29.0 h1:DLjwM6jHnfymwN3j3gyuJW3v+dR16YlM05zMPV0QWCY=
github.com/go-fleettools/landingkit v0.29.0/go.mod h1:jSXTO7FVKNXCK1aJjLq7H7x8d8wxDoXe3ncXWGcAKRE=
4 changes: 4 additions & 0 deletions hugo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -106,3 +106,7 @@ disableKinds = ['taxonomy', 'term', 'rss', 'sitemap', '404']
[[params.families]]
name = "Workspace"
what = "An arena for loops: `Use`, `Reset`, `Detach` — results stop costing the garbage collector from one pass to the next."

# The architectures the tests RUN on, read from the library's CI.
[params.mantra]
goarch = ["amd64", "arm64", "riscv64", "loong64", "ppc64le", "s390x", "arm"]
12 changes: 6 additions & 6 deletions layouts/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -79,15 +79,15 @@ <h2>The example above, <i>actually run</i>.</h2>
<h2>The n-dimensional array, <i>without</i> cgo.</h2>
<p class="lead">NumPy is the lingua franca of numerical computing, but in Go the choices are <code>gonum</code> (matrix-centric, amd64-only assembly) or a C extension. go-ndarray brings the <b>n-dimensional array</b> vocabulary — shapes, strided views, broadcasting, ufuncs, reductions and linear algebra — to Go with <b>no cgo</b>, cross-compiling to a static binary everywhere. The hot paths are multicore, and SIMD on amd64, arm64, ppc64le, loong64 and riscv64.</p>
<div class="grid" id="quality">
<div class="card"><div class="ico">🐹</div><h3>Pure Go</h3><p><code>CGO_ENABLED=0</code> across the org. No cgo, no BLAS shim.</p></div>
{{ if not (partial "mantra-on.html" $) }}<div class="card"><div class="ico">🐹</div><h3>Pure Go</h3><p><code>CGO_ENABLED=0</code> across the org. No cgo, no BLAS shim.</p></div>{{ end }}
<div class="card"><div class="ico">✅</div><h3>100% test coverage</h3><p>Gated in CI, differentially checked against <code>numpy</code>.</p></div>
<div class="card"><div class="ico">🔢</div><h3>NumPy semantics</h3><p>Row-major strided arrays, <b>NumPy broadcasting</b>, and NumPy basic-indexing <code>Slice</code> returning strided views that share data.</p></div>
<div class="card"><div class="ico">♻️</div><h3><code>Workspace</code> arena for loops</h3><p>Bind the inputs with <code>ws.Use</code>, compute as usual, <code>ws.Reset()</code> at the end of each pass: results stop costing the garbage collector anything. On a Zen 3, <code>x + y</code> on 1&nbsp;024 elements drops from 2.6 to 0.38&nbsp;µs, Go against Go.</p></div>
<div class="card"><div class="ico">⚡</div><h3>SIMD on every 64-bit target</h3><p>go-asmgen SIMD kernels on amd64 (SSE2, AVX2/FMA picked at run time), arm64 (NEON), ppc64le (VSX), loong64 (LASX, when the CPU has it), riscv64 (RVV, when the CPU has it) and s390x (vector facility, measured on a real IBM z17); the 32-bit targets run the same pure-Go code those kernels are tested against.</p></div>
<div class="card"><div class="ico">🎯</div><h3>Accurate <code>Exp</code>/<code>Log</code></h3><p>Ports of Arm's optimized-routines: worst 0.504 / 0.508 ULP against a 300-bit reference, and correct where Go's amd64 <code>math.Exp</code> returns +Inf (<a href="https://github.com/golang/go/issues/81995"><u>golang/go#81995</u></a>) and <code>math.Log</code> is wrong on subnormals (<a href="https://github.com/golang/go/issues/56600"><u>golang/go#56600</u></a>).</p></div>
<div class="card"><div class="ico">🧪</div><h3>Multi-arch CI</h3><p>The suite runs on amd64, arm64 and 386 natively and on riscv64/loong64/ppc64le/s390x/arm under qemu, on Linux, macOS and Windows, and compiles for every <code>GOOS/GOARCH</code> pair Go supports; v0.2.0 was also run on real amd64, arm64, ppc64le, riscv64 and loong64 hardware.</p></div>
<div class="card"><div class="ico">⚡</div><h3>SIMD on every 64-bit target</h3><p>{{ if not (and $.Site.Params.mantra $.Site.Params.mantra.goarch) }}go-asmgen SIMD kernels on amd64 (SSE2, AVX2/FMA picked at run time), arm64 (NEON), ppc64le (VSX), loong64 (LASX, when the CPU has it), riscv64 (RVV, when the CPU has it) and s390x (vector facility, measured on a real IBM z17); the 32-bit targets run the same pure-Go code those kernels are tested against.{{ end }}</p></div>
<div class="card"><div class="ico">🎯</div><h3>Accurate <code>Exp</code>/<code>Log</code></h3><p>{{ if not (and $.Site.Params.mantra $.Site.Params.mantra.goarch) }}Ports of Arm's optimized-routines: worst 0.504 / 0.508 ULP against a 300-bit reference, and correct where Go's amd64 <code>math.Exp</code> returns +Inf (<a href="https://github.com/golang/go/issues/81995"><u>golang/go#81995</u></a>) and <code>math.Log</code> is wrong on subnormals (<a href="https://github.com/golang/go/issues/56600"><u>golang/go#56600</u></a>).{{ end }}</p></div>
<div class="card"><div class="ico">🧪</div><h3>Multi-arch CI</h3><p>{{ if not (and $.Site.Params.mantra $.Site.Params.mantra.goarch) }}The suite runs on amd64, arm64 and 386 natively and on riscv64/loong64/ppc64le/s390x/arm under qemu, on Linux, macOS and Windows, and compiles for every <code>GOOS/GOARCH</code> pair Go supports; v0.2.0 was also run on real amd64, arm64, ppc64le, riscv64 and loong64 hardware.{{ end }}</p></div>
<div class="card"><div class="ico">💎</div><h3>The cgo-free ndarray that was missing</h3><p>Ruby has no cgo-free ndarray (<code>Numo::NArray</code> and <code>NMatrix</code> are C extensions) and <code>gonum</code>'s optimized assembly is amd64-only. go-ndarray pairs a portable pure-Go core with multicore fan-out and SIMD kernels.</p></div>
<div class="card"><div class="ico">⚖️</div><h3>BSD-3-Clause</h3><p><code>Exp</code> and <code>Log</code> are MIT-licensed ports of Arm's optimized-routines.</p></div>
{{ if not (partial "mantra-on.html" $) }}<div class="card"><div class="ico">⚖️</div><h3>BSD-3-Clause</h3><p><code>Exp</code> and <code>Log</code> are MIT-licensed ports of Arm's optimized-routines.</p></div>{{ end }}
</div>
</div></section>

Expand Down Expand Up @@ -140,6 +140,6 @@ <h2>The cgo-free ndarray the Go and Ruby ecosystems lacked.</h2>
</div>
</div></section>

<footer><div class="wrap"><span>go-ndarray · <a href="https://github.com/go-ndarray">go-ndarray on GitHub</a>{{ if not (partial "mantra-on.html" .) }} · BSD-3-Clause{{ end }}</span>{{ if not (partial "mantra-on.html" .) }}<span>Pure Go · CGO_ENABLED=0 · no BLAS shim</span>{{ end }}</div></footer>
<footer><div class="wrap"><span>go-ndarray · <a href="https://github.com/go-ndarray">go-ndarray on GitHub</a>{{ if not (partial "mantra-on.html" .) }} · BSD-3-Clause{{ end }}</span>{{ if not (partial "mantra-on.html" .) }}<span>{{ if not (partial "mantra-on.html" $) }}Pure Go · {{ end }}{{ if not (partial "mantra-on.html" $) }}CGO_ENABLED=0 · {{ end }}no BLAS shim</span>{{ end }}</div></footer>
</body>
</html>
Loading