research/determinism-cost.md §4.6, in the same record and by the same procedure: the 192 payloads decoded again on every platform with every kernel set it runs (15 new runs, 0 decodes differing from the record's), and the record's time and energy runs repeated in one session per host beside the record's own build and the float decoder. On x86_64 host A the integer decode on the narrow kernels took 144.8 ms and 12.43 J of marginal package energy at quality 6 against 210.7 ms and 14.03 J for the float decode beside it (the record's build: 728.0 ms, 92.14 J). On the build host its own CPU energy fell from 11.01 J to 6.43 J at quality 6 and is still above the float decode's 1.28 J by that count. Host B's integer decode was measured before and after, without a float decode beside it. The scripts that took the readings are in runs/; decode-throughput.md notes the new sets; the changelog records the change. Co-Authored-By: Claude Opus 5.5 <[email protected]>
28 lines
2.3 KiB
Shell
28 lines
2.3 KiB
Shell
# The 192 integer decodes on the build host's platforms with the narrow kernel sets (binaries of mac-build.sh <tag>).
|
|
set -euo pipefail
|
|
TAG=${1:?binary tag}; shift
|
|
W=$RB_ROOT/det1/work; B=$RB_ROOT/idf/bin; X=$RB_ROOT/idf/xplat; mkdir -p $X
|
|
OS="macOS $(sw_vers -productVersion)"; HW="arm64 desktop SoC, 24 performance and 8 efficiency cores"
|
|
meta() { printf '{"system": "%s", "hardware": "%s", "target": "%s", "fabric": "%s", "kernels": "%s", "threads": "%s", "rustc": "%s", "runtime": "%s", "measured": "%s"}\n' "$OS" "$HW" "$1" "$2" "$3" "$4" "$(rustc --version | cut -d" " -f2)" "$5" "$(date +%F)"; }
|
|
for step in "$@"; do case $step in
|
|
neon)
|
|
WAI_INT_ISA=neon $B/native.$TAG decode $W/jobs.dash.tsv > $X/macos-arm64-cpu-isa-neon.tsv
|
|
meta aarch64-apple-darwin CPU "fast, kernel set neon" "all (32)" native > $X/macos-arm64-cpu-isa-neon.json ;;
|
|
neon1)
|
|
WAI_INT_ISA=neon WAI_INT_THREADS=1 $B/native.$TAG decode $W/jobs.dash.tsv > $X/macos-arm64-cpu-1t-isa-neon.tsv
|
|
meta aarch64-apple-darwin CPU "fast, kernel set neon" 1 native > $X/macos-arm64-cpu-1t-isa-neon.json ;;
|
|
wide)
|
|
WAI_INT_ISA=wide $B/native.$TAG decode $W/jobs.dash.tsv > $X/macos-arm64-cpu-isa-wide.tsv
|
|
meta aarch64-apple-darwin CPU "fast, kernel set wide" "all (32)" native > $X/macos-arm64-cpu-isa-wide.json ;;
|
|
gpu)
|
|
WAI_INT_ISA=neon $B/gpu.$TAG --gpu decode $W/jobs.dash.tsv > $X/macos-arm64-gpu-metal-isa-neon.raw 2> $X/macos-arm64-gpu-metal-isa-neon.err
|
|
cut -f1-4 $X/macos-arm64-gpu-metal-isa-neon.raw > $X/macos-arm64-gpu-metal-isa-neon.tsv
|
|
meta aarch64-apple-darwin "GPU, Metal, integrated (80 cores)" "fast, kernel set neon" "all (32) for graphs off the device" "wgpu 30.0.1, $(grep -o 'key=[^ ]*' $X/macos-arm64-gpu-metal-isa-neon.err | head -1)" > $X/macos-arm64-gpu-metal-isa-neon.json ;;
|
|
wasm)
|
|
S=$RB_ROOT/idf/wasm-shards; rm -rf $S; mkdir -p $S
|
|
awk "{print > (\"$S/jobs.\" (NR-1)%8)}" $W/jobs.dash.tsv
|
|
for f in $S/jobs.?; do wasmtime run --dir $W::$W --dir $S::$S $B/wasm.$TAG decode $f > $f.out & done; wait
|
|
cat $S/jobs.?.out > $X/wasm32-wasip2-isa-wide.tsv
|
|
meta wasm32-wasip2 "CPU, WebAssembly" "fast, kernel set wide (the only set on wasm)" "1 (eight decoder processes side by side)" "$(wasmtime --version | cut -d' ' -f1-2)" > $X/wasm32-wasip2-isa-wide.json ;;
|
|
esac; wc -l $X/*.tsv | tail -1; done
|
|
ls $X
|