Skip to content

Merge CTPerf into NIXLKVBench - #433

Merged
karya0 merged 1 commit into
ai-dynamo:mainfrom
aranadive:merge_ctperf_kvbench
Jul 3, 2025
Merged

karya0 merged 1 commit into
ai-dynamo:mainfrom
aranadive:merge_ctperf_kvbench

Conversation

@aranadive

@aranadive aranadive commented Jun 5, 2025 •

Copy link
Copy Markdown
Contributor

(This is essentially extending the NIXLKVBench benchmark to cover KV Cache transfers over network which was being added separately in #263). Fixes NIX-144.

NIXL KVBench

NIXL KVBench is a benchmarking utility for testing KVCache transfers in large language models (LLMs) using the NIXL runtime. It supports various model architectures, parallelism strategies, and custom traffic simulation for asymmetric workloads.


🚀 Features

🔧 KVBench Commands

Benchmark KVCache transfers with support for:

  • Block and Layer access patterns
  • Tensor and Pipeline parallelism
  • Integration with nixlbench

Commands:

  • plan: Generate recommended nixlbench command configs
  • profile: Run actual benchmarks
  • kvcache, io-size: Inspect model memory/transfer characteristics

📶 CTP (Custom Traffic Performance)

Simulate and analyze asymmetric data transfers using traffic matrices:

  • YAML-configurable traffic patterns
  • Sequential or single-pattern execution
  • Reports total/isolated latency, bandwidth, and congestion response
  • JSON output and buffer verification supported

✅ Supported Architectures

  • DeepSeek R1
  • LLaMA 3.1
  • More supported via custom config YAMLs

🧪 Example: KVBench Profile

Run benchmark for DeepSeek R1 with block access pattern:

python main.py profile \
  --model ./examples/model_deepseek_r1.yaml \
  --model_config ./examples/block-tp1-pp8.yaml \
  --backend GDS \
  --source gpu \
  --etcd-endpoints "http://localhost:2379"

nixlbench \
  --backend GDS \
  --source gpu \
  --etcd-endpoints http://localhost:2379 \
  --max_batch_size 5958 \
  --start_batch_size 5958 \
  --max_block_size 589824 \
  --start_block_size 589824 \
  --target_seg_type VRAM

🧪 Example: CTP Sequential Test

python main.py sequential-ct-perftest ./config.yaml \
  --verify-buffers \
  --json-output-path ./results.json

⚙️ Getting Started

  • Python or Docker setup supported
  • Commands:
    • plan, profile, kvcache, io-size
    • ct-perftest, sequential-ct-perftest

📚 Documentation

  • See the /docs directory for:
    • Setup tutorials
    • Creating model config files

@github-actions

github-actions Bot commented Jun 5, 2025

Copy link
Copy Markdown

👋 Hi aranadive! Thank you for contributing to ai-dynamo/nixl.

Your PR reviewers will review your contribution then trigger the CI to test your changes.

🚀

@copy-pr-bot

copy-pr-bot Bot commented Jun 19, 2025

Copy link
Copy Markdown

This pull request requires additional validation before any workflows can run on NVIDIA's runners.

Pull request vetters can view their responsibilities here.

Contributors can view more details about this message here.

@x41lakazam

Copy link
Copy Markdown
Contributor

I have updated the CT perftest files with the latest working version

@aranadive For my part, it is ready to be merged

@aranadive
aranadive marked this pull request as ready for review June 27, 2025 09:17
@aranadive

Copy link
Copy Markdown
Contributor Author

/ok to test d912d04

@aranadive

Copy link
Copy Markdown
Contributor Author

/build

@aranadive aranadive closed this Jun 27, 2025
@aranadive aranadive reopened this Jun 27, 2025
@aranadive aranadive changed the title Merge ctperf kvbench MErge CTPerf into NIXLKVBench Jun 27, 2025
@aranadive aranadive changed the title MErge CTPerf into NIXLKVBench Merge CTPerf into NIXLKVBench Jun 27, 2025
@aranadive

Copy link
Copy Markdown
Contributor Author

/build

@aranadive

Copy link
Copy Markdown
Contributor Author

/build

@aranadive

Copy link
Copy Markdown
Contributor Author

/ok to test b5608aa

@aranadive

Copy link
Copy Markdown
Contributor Author

/build

@aranadive

Copy link
Copy Markdown
Contributor Author

/ok to test 4db2ff0

Add workload perftest to NIXL KVBench
@barneuman

Copy link
Copy Markdown
Contributor

/build

@barneuman

Copy link
Copy Markdown
Contributor

/ok to test 4dd3d2c

1 similar comment
@barneuman

Copy link
Copy Markdown
Contributor

/ok to test 4dd3d2c

@roiedanino

Copy link
Copy Markdown
Contributor

/build

@roiedanino

Copy link
Copy Markdown
Contributor

/ok to test 4dd3d2c

This branch was previously deployed

2 inactive deployments
GITLAB — 4dd3d2c9 Deployed Jul 3, 2025 by copy-pr-bot[bot]
SWX_AWS — 4dd3d2c9 Deployed Jul 3, 2025 by copy-pr-bot[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants