← Back to Blog
Benchmarks

Speeding Up QuantLib with AADC: ~300× Faster

Independent blog post by Serg Kozyarchuk demonstrating a 300× speedup on a 10,000 OIS swap portfolio using AADC with QuantLib — no QuantLib source code modifications required.

Dmitri Goloubentsev
Dmitri Goloubentsev
· 1 min read
QuantLib AADC OIS swaps benchmark independent review performance

Serg Kozyarchuk, an independent quantitative developer, published a detailed blog post documenting his experience integrating AADC with QuantLib. Using a portfolio of 10,000 OIS (Overnight Index Swap) instruments, he measured the end-to-end performance of QuantLib’s native pricing versus AADC-compiled kernel evaluation.

The Setup

The benchmark uses QuantLib’s standard OIS pricing engine, with no modifications to QuantLib’s source code. AADC operates as a black box around QuantLib: it records the pricing operations through operator overloading, compiles the captured computation graph, and replays the compiled kernel for subsequent evaluations.

The Results

The AADC-compiled kernel prices the 10,000 OIS portfolio approximately 300× faster than QuantLib’s native implementation. This includes full curve sensitivities (delta risk) via adjoint mode, which would require thousands of bump-and-revalue iterations in the traditional approach.

The recording phase (where AADC captures QuantLib’s computation graph) takes a one-time cost of a few minutes. After that, every subsequent evaluation runs at compiled speed. For intraday risk management where the same portfolio is repriced thousands of times against market data updates, the recording cost is amortized to negligibility.

Why This Matters

This is an independent, third-party benchmark, not produced by MatLogica. It demonstrates that AADC’s acceleration works on real-world QuantLib code without requiring QuantLib expertise, C++ refactoring, or access to QuantLib’s internals. The black-box recording approach works on the library as-is.

Read the full blog post


Published by MatLogica. Implemented using AADC, a commercial adjoint AD compiler (matlogica.com).

Want to see these results on your own portfolio?

Get in Touch

Interested in these opportunities?

Let's arrange a free demo for you and your team.

Book a Demo