← GPU latency results

gpu/linalg_ad_latency

profile: nvidia-gpuhardware: NVIDIA A100 80GB PCIedate: 2026-11-21 08:23:11Ztenferro: ce9125d0cff4unit: ms
Accepted result provenance. Source run 44883416365, attempt 1 · raw artifact 14700186475 · provenance and SHA-256 digests. Raw artifacts have finite retention; this artifact download availability ends at 2027-02-19T08:07:55Z (GitHub access required). Expired artifacts are not replaced by another run.

This suite has no throughput-regime case. Every measured case is declared `latency`, so its results are published as per-call latency and overhead here and on the GPU latency page

Latency and per-call overhead (10)

Dominated by launch, dispatch and synchronization; these numbers are overhead, not device throughput.

casegroupvs PyTorchvs JAXnot measurednot okflags
linalg_ad_small_grad_sum_eigh_jvp_f64_4grad_sum_eigh_jvptrace 0.91xtrace 1.05x---
linalg_ad_small_grad_sum_eigh_vjp_f64_4grad_sum_eigh_vjptrace 0.87xtrace 1.12x---
linalg_ad_small_grad_sum_lu_jvp_f64_4grad_sum_lu_jvp-----
linalg_ad_small_grad_sum_lu_vjp_f64_4grad_sum_lu_vjp-----
linalg_ad_small_grad_sum_qr_jvp_f64_4grad_sum_qr_jvp-----
linalg_ad_small_grad_sum_qr_vjp_f64_4grad_sum_qr_vjptrace 0.66x----
linalg_ad_small_grad_sum_solve_jvp_f64_4grad_sum_solve_jvp-----
linalg_ad_small_grad_sum_solve_vjp_f64_4grad_sum_solve_vjp-trace 1.92x---
linalg_ad_small_grad_sum_svd_s_jvp_f64_4grad_sum_svd_s_jvptrace 1.34xtrace 1.26x---
linalg_ad_small_grad_sum_svd_s_vjp_f64_4grad_sum_svd_s_vjp-----

Charts below are ordered best first (smallest ratio).

linalg_ad_small_grad_sum_solve_vjp_f64_4 grad_sum_solve_vjp · n=7

bar = median time (log scale) · shorter (left) is faster · dashed line = PyTorch (0.94 ms)jax-cuda0.2426 mspytorch-cuda0.94 mstenferro-cuda-trace0.4649 ms · 0.49x

linalg_ad_small_grad_sum_lu_vjp_f64_4 grad_sum_lu_vjp · n=7

bar = median time (log scale) · shorter (left) is faster · dashed line = PyTorch (0.7993 ms)jax-cuda0.1944 mspytorch-cuda0.7993 mstenferro-cuda-trace0.4603 ms · 0.58x

linalg_ad_small_grad_sum_qr_vjp_f64_4 grad_sum_qr_vjp · n=7

bar = median time (log scale) · shorter (left) is faster · dashed line = PyTorch (0.8053 ms)jax-cuda0.2546 mspytorch-cuda0.8053 mstenferro-cuda-trace0.5325 ms · 0.66x

linalg_ad_small_grad_sum_lu_jvp_f64_4 grad_sum_lu_jvp · n=7

bar = median time (log scale) · shorter (left) is faster · dashed line = PyTorch (0.6337 ms)jax-cuda0.2407 mspytorch-cuda0.6337 mstenferro-cuda-trace0.45 ms · 0.71x

linalg_ad_small_grad_sum_solve_jvp_f64_4 grad_sum_solve_jvp · n=7

bar = median time (log scale) · shorter (left) is faster · dashed line = PyTorch (0.5741 ms)jax-cuda0.2214 mspytorch-cuda0.5741 mstenferro-cuda-trace0.4587 ms · 0.80x

linalg_ad_small_grad_sum_eigh_vjp_f64_4 grad_sum_eigh_vjp · n=7

bar = median time (log scale) · shorter (left) is faster · dashed line = PyTorch (0.4833 ms)jax-cuda0.3745 mspytorch-cuda0.4833 mstenferro-cuda-trace0.4187 ms · 0.87x

linalg_ad_small_grad_sum_eigh_jvp_f64_4 grad_sum_eigh_jvp · n=7

bar = median time (log scale) · shorter (left) is faster · dashed line = PyTorch (0.4222 ms)jax-cuda0.3654 mspytorch-cuda0.4222 mstenferro-cuda-trace0.3828 ms · 0.91x

linalg_ad_small_grad_sum_qr_jvp_f64_4 grad_sum_qr_jvp · n=7

bar = median time (log scale) · shorter (left) is faster · dashed line = PyTorch (0.4625 ms)jax-cuda0.2658 mspytorch-cuda0.4625 mstenferro-cuda-trace0.5549 ms · 1.20x

linalg_ad_small_grad_sum_svd_s_jvp_f64_4 grad_sum_svd_s_jvp · n=7

bar = median time (log scale) · shorter (left) is faster · dashed line = PyTorch (0.5971 ms)pytorch-cuda0.5971 msjax-cuda0.6357 mstenferro-cuda-trace0.8013 ms · 1.34x

linalg_ad_small_grad_sum_svd_s_vjp_f64_4 grad_sum_svd_s_vjp · n=7

bar = median time (log scale) · shorter (left) is faster · dashed line = PyTorch (0.497 ms)jax-cuda0.4533 mspytorch-cuda0.497 mstenferro-cuda-trace0.7945 ms · 1.60x

Original report

GPU Linalg JVP/VJP Benchmark Results

GPU Information

CPU Information

Median ± IQR (ms). Missing backends are shown as -.

tenferro-rs JVP/VJP use trace-mode AdContext on CUDA; PyTorch uses torch.func.jvp / vjp on CUDA. JAX uses an explicitly lowered/compiled whole-operation JIT; compilation and lazy initialization occur before sampling. Primal loss and first-order derivatives with respect to A are both returned; the check that backs each row is stated below, and a row that carries none is marked as not checked. RHS and derivative seeds are prepared before timing. Standard and latency AD rows time one prepared operation plus device completion per call on every backend, repeated in bounded batches. tenferro uses Runtime::run on a reusable caller-held CUDA engine. Fixtures, transfers, graph construction, compilation, preparation and initialization are untimed; output conversion and verification follow the stopped clock. Small rows measure API latency, not kernel throughput. Legacy session-entry measurements require recollection (issue #309). Any unsupported row retains its actual reason in the raw records. Inputs are uploaded to the GPU before timed runs; initial host-to-device transfer is outside the timed region. Timed runs include the host API call and backend-native device synchronization without downloading AD outputs in the timed region. Small cases (n=2, 4, 8) use bounded batches of repeated declared operations with retained outputs. They compare steady-state API latency, not isolated GPU throughput. Native synchronization completes each operation; numerical downloads are outside timing. This suite exists to measure single-call latency and per-op overhead: the device kernels are a small fraction of each row, so the numbers are not GPU throughput. GPU-sized AD results live in result/nvidia-gpu/gpu/linalg_jvp_vjp.md.

Linalg JVP/VJP Benchmark Items

suite benchmark dtype shape tenferro-rs CUDA trace tenferro-rs CUDA eager, per call, incl. AD prepare tenferro-rs CUDA trace (deferred batch throughput) PyTorch CUDA JAX CUDA JIT
small grad_sum_eigh_jvp f64 4x4 0.383 ± 0.003 - - 0.422 ± 0.013 0.365 ± 0.008
small grad_sum_eigh_vjp f64 4x4 0.419 ± 0.004 - - 0.483 ± 0.020 0.375 ± 0.024
small grad_sum_lu_jvp f64 4x4 0.450 ± 0.022 - - 0.634 ± 0.025 0.241 ± 0.012
small grad_sum_lu_vjp f64 4x4 0.460 ± 0.005 - - 0.799 ± 0.021 0.194 ± 0.018
small grad_sum_qr_jvp f64 4x4 0.555 ± 0.014 - - 0.463 ± 0.026 0.266 ± 0.026
small grad_sum_qr_vjp f64 4x4 0.533 ± 0.028 - - 0.805 ± 0.021 0.255 ± 0.012
small grad_sum_solve_jvp f64 4x4,rhs=1 0.459 ± 0.005 - - 0.574 ± 0.014 0.221 ± 0.031
small grad_sum_solve_vjp f64 4x4,rhs=1 0.465 ± 0.004 - - 0.940 ± 0.026 0.243 ± 0.005
small grad_sum_svd_s_jvp f64 4x4 0.801 ± 0.007 - - 0.597 ± 0.007 0.636 ± 0.011
small grad_sum_svd_s_vjp f64 4x4 0.795 ± 0.012 - - 0.497 ± 0.072 0.453 ± 0.017

Sampling and unsupported routes

Case Backend Ops/sample Samples Scope / reason
linalg_ad_small_grad_sum_svd_s_jvp_f64_4 tenferro-cuda-trace 4 15 steady_state_host_api_plus_device_sync
linalg_ad_small_grad_sum_svd_s_vjp_f64_4 tenferro-cuda-trace 4 15 steady_state_host_api_plus_device_sync
linalg_ad_small_grad_sum_qr_jvp_f64_4 tenferro-cuda-trace 4 15 steady_state_host_api_plus_device_sync
linalg_ad_small_grad_sum_qr_vjp_f64_4 tenferro-cuda-trace 4 15 steady_state_host_api_plus_device_sync
linalg_ad_small_grad_sum_eigh_jvp_f64_4 tenferro-cuda-trace 8 15 steady_state_host_api_plus_device_sync
linalg_ad_small_grad_sum_eigh_vjp_f64_4 tenferro-cuda-trace 8 15 steady_state_host_api_plus_device_sync
linalg_ad_small_grad_sum_lu_jvp_f64_4 tenferro-cuda-trace 8 15 steady_state_host_api_plus_device_sync
linalg_ad_small_grad_sum_lu_vjp_f64_4 tenferro-cuda-trace 8 15 steady_state_host_api_plus_device_sync
linalg_ad_small_grad_sum_solve_jvp_f64_4 tenferro-cuda-trace 8 15 steady_state_host_api_plus_device_sync
linalg_ad_small_grad_sum_solve_vjp_f64_4 tenferro-cuda-trace 8 15 steady_state_host_api_plus_device_sync
linalg_ad_small_grad_sum_svd_s_jvp_f64_4 pytorch-cuda 4 15 steady_state_host_api_plus_device_sync
linalg_ad_small_grad_sum_svd_s_vjp_f64_4 pytorch-cuda 8 15 steady_state_host_api_plus_device_sync
linalg_ad_small_grad_sum_qr_jvp_f64_4 pytorch-cuda 8 15 steady_state_host_api_plus_device_sync
linalg_ad_small_grad_sum_qr_vjp_f64_4 pytorch-cuda 4 15 steady_state_host_api_plus_device_sync
linalg_ad_small_grad_sum_eigh_jvp_f64_4 pytorch-cuda 8 15 steady_state_host_api_plus_device_sync
linalg_ad_small_grad_sum_eigh_vjp_f64_4 pytorch-cuda 8 15 steady_state_host_api_plus_device_sync
linalg_ad_small_grad_sum_lu_jvp_f64_4 pytorch-cuda 4 15 steady_state_host_api_plus_device_sync
linalg_ad_small_grad_sum_lu_vjp_f64_4 pytorch-cuda 4 15 steady_state_host_api_plus_device_sync
linalg_ad_small_grad_sum_solve_jvp_f64_4 pytorch-cuda 4 15 steady_state_host_api_plus_device_sync
linalg_ad_small_grad_sum_solve_vjp_f64_4 pytorch-cuda 4 15 steady_state_host_api_plus_device_sync
linalg_ad_small_grad_sum_svd_s_jvp_f64_4 jax-cuda 4 15 steady_state_host_api_plus_device_sync
linalg_ad_small_grad_sum_svd_s_vjp_f64_4 jax-cuda 8 15 steady_state_host_api_plus_device_sync
linalg_ad_small_grad_sum_qr_jvp_f64_4 jax-cuda 8 15 steady_state_host_api_plus_device_sync
linalg_ad_small_grad_sum_qr_vjp_f64_4 jax-cuda 16 15 steady_state_host_api_plus_device_sync
linalg_ad_small_grad_sum_eigh_jvp_f64_4 jax-cuda 8 15 steady_state_host_api_plus_device_sync
linalg_ad_small_grad_sum_eigh_vjp_f64_4 jax-cuda 8 15 steady_state_host_api_plus_device_sync
linalg_ad_small_grad_sum_lu_jvp_f64_4 jax-cuda 16 15 steady_state_host_api_plus_device_sync
linalg_ad_small_grad_sum_lu_vjp_f64_4 jax-cuda 16 15 steady_state_host_api_plus_device_sync
linalg_ad_small_grad_sum_solve_jvp_f64_4 jax-cuda 16 15 steady_state_host_api_plus_device_sync
linalg_ad_small_grad_sum_solve_vjp_f64_4 jax-cuda 8 15 steady_state_host_api_plus_device_sync

Loss Definitions