NVIDIA added a cuBLAS algorithm that accelerates real and complex matrix multiplication while preserving precision. Molecular and materials simulation developers can use fast GPU compute units to reduce runtime without changing existing application code.

1. Switching compute paths while preserving precision

In CUDA Toolkit 13.4.2, cuBLAS splits double-precision (FP64) inputs into integer chunks, multiplies them on GPU matrix units called Tensor Cores, and reconstructs the result. Automatic dynamic precision determines the required number of mantissa bits at runtime.

The library selects Ozaki-I or Ozaki-II based on performance. If the required mantissa bits exceed the default or user-defined limit, it switches to the GPU's native FP64 path to preserve accuracy.

For real matrix multiplication, DGEMM, Ozaki-II multiplies remainders from dividing large integers by smaller numbers and reconstructs the result. It needs fewer operations than Ozaki-I, which repeatedly multiplies chunks. NVIDIA says matching FP64 accuracy requires roughly twice as many Tensor Core matrix multiplications with Ozaki-I as with Ozaki-II.

2. Reducing complex arithmetic to two multiplications

Complex matrix multiplication, ZGEMM, traditionally uses four real matrix multiplications of the same size. The 2M method reduces this to two using Ozaki-II's exact integer arithmetic. Intermediate additions and subtractions are also performed exactly with integers.

NVIDIA says this method has been used since CUDA Toolkit 13.4. The source's formula for conventional complex multiplication below shows four multiplications combining real and imaginary parts.


A = Ar + i(Ai); B = Br + i(Bi)

C = A x B = (Ar·Br − Ai·Bi) + i(Ar·Bi + Ai·Br)

3. Peak speedups and throughput by GPU

NVIDIA reports DGEMM with Ozaki-II was up to 5.5x faster than native GPU FP64 on VR NVL72 and up to 3.9x on GB200. On RTX PRO 6000 Blackwell Server Edition, it was up to 23x faster and 10x faster even for the smallest matrix tested.

On GB200, speedups increased with matrix size. NVIDIA reports peak DGEMM throughput of 175 TFLOPS on VR NVL72, 147 TFLOPS on GB200, and 37 TFLOPS on RTX PRO 6000. These are peak throughput results from different systems.

4. Shorter runtimes for molecular and materials calculations

A CCSD quantum chemistry case calculating electron correlation processed five molecular complexes from the S22 database on a single GPU. NVIDIA reports overall speedups over native FP64 of 2x on VR NVL72 and 1.4x on GB200. Mixed precision, combining different numerical precisions with the mantissa fixed at 32 bits, achieved 5x and 3.5x, respectively.

The experiment used the frozen-core approach, which holds inner atomic electrons fixed, and the cc-pVTZ basis set to represent electronic states mathematically. NVIDIA reports correlation energy errors below 10⁻¹⁴ Eh with the FP64 precision setting. Eh denotes the hartree, an energy unit.

For a uracil dimer calculation in the same study, throughput was reported for both the full run and individual matrix multiplications. NVIDIA's figures below show how overall workload throughput can differ from core operation throughput even within one problem.

Table: Throughput for the uracil dimer calculation

Conditions: Single Rubin GPU, cuBLAS in CUDA Toolkit 13.4.2, frozen-core CCSD/cc-pVTZ, Ozaki-II mantissa fixed at 32 bits

Unit: TFLOPS

Shorter runtimes for molecular and materials calculations
Measurement scopeThroughput
Full run173
Peak individual matrix multiplication368
Average individual matrix multiplication200

For this 32-bit mantissa calculation, considering both peak core operation throughput and full-run throughput helps clarify the speedup in actual workloads.

The Epsilon module of the materials science code BerkeleyGW ran the Si998 benchmark on 32 GPUs. NVIDIA reports that the new method with a 53-bit mantissa was 3.9x faster on GB200 and 6.6x faster on VR NVL72 than each system's native ZGEMM. Overall runtime improved by 5.8x when comparing native Blackwell arithmetic with the new method on VR NVL72.

NVIDIA says both automatic precision and the 53-bit mantissa setting matched the reference computation's matrix elements to 10 decimal places.

5. Checking real-world speed and accuracy with the latest tools

The benefit of high-throughput integer Tensor Cores is pursuing both FP64 accuracy and speed. However, integer decomposition, reconstruction, and intermediate storage consume compute and memory resources. Small matrices on GB200 showed no benefit, so the native FP64 path was selected. The CCSD case reported energy errors below 10⁻¹⁰ Eh with 32-bit mixed precision, so error tolerance also matters when choosing faster computation.

To get started, install the latest CUDA Toolkit and review the cuBLAS floating-point emulation documentation and official samples. The strategy-setting function is cublasSetEmulationStrategy(). The documentation also explains how to control mantissa bits directly.

Ozaki-II and 2M are practical cuBLAS extensions that use Tensor Core performance to ease FP64 matrix multiplication bottlenecks while automatically accounting for precision requirements.