[GH-ISSUE #4323] [Engine] Proposal: a native single-card Intel Gaudi2 backend (opt-in hpu/) #1907

Closed
opened 2026-11-04 01:55:13 +07:00 by bsakaguchi · 1 comment
Owner

Originally created by @JChen-318 on GitHub (Oct 27, 2026).
Original GitHub issue: https://github.com/Niko1221/Strata/issues/4323

Area

[Engine] (speed, kernels, models, the server and API)

What do you want to do?

Run Strata on an Intel Gaudi2 accelerator. Strata has no path for Gaudi today: the card is neither CUDA, HIP nor
SYCL, and its compute engines (MME matrix units, TPC vector cores) are programmed through Habana's SynapseAI graph API
and TPC-C kernels.

I have a working backend for one Gaudi2 (HL-225, 96 GB HBM) in a fork,
JChen-318/gaudi2-single-card-strata, based on 296b59d.
It keeps Strata's server, and only the engine underneath is new.

What runs today:

  • Qwen3.8-Flash-Next IQ4_XS, fully resident in HBM, with a 262,144-token context.
  • A DFlash2 drafter for speculative decoding.
  • The measurements, raw data and limits are in the benchmark report PR #4322.
    • Prompt: 2,086 / 3,179 / 2,915 tok/s at 4K / 32K / 125K.
    • Decode: 105 / 114 / 106 tok/s.
    • Needles: 6/6 at 32k and 128k.

Question for the maintainers: would you take this upstream as an opt-in backend? If yes, I would split it
into focused PRs, in this order.

  1. serve/ (about 290 changed lines, tests included): recognise an hpu backend in the Monitor telemetry.
    • It reads hl-smi instead of nvidia-smi/rocm-smi.
    • The Monitor gets a prefill rate for engines that print only PP n total ms.
    • Nothing changes for the other backends.
  2. hpu/, a self-contained directory with its own CMake project (cmake -S hpu).
    • The top-level CMake does not build it, so existing builds stay byte-identical.
    • About 550 files: the engine, about 110 TPC kernels, and CPU-side unit tests that run without the card.
    • It needs SynapseAI 1.24.x and tpc-clang from Habana's packages. A Docker image on Habana's base image is included.
  3. A docs page (docs/GAUDI2.md) covering setup, the measured numbers and the limits.

Tradeoffs, as I see them:

  • Maintenance. It is Gaudi-specific code: SynapseAI graphs and TPC-C kernels. Probably nobody else on the
    project has the hardware. I would maintain it, answer its issues, and run hardware validation before each change.
  • CI. It cannot be built without SynapseAI. A CI job could at most run the CPU-side unit tests, and only if the
    SDK headers were stubbed.
  • Divergence. The fork is about 2,400 commits behind main. The first step would be a rebase and re-validation
    on the card.
  • Scope. It supports one model family (Qwen3.8-Flash-Next geometry) on one card, and serves one request at a time.
    The first request at a new context size compiles its graphs (seconds), and the backend has no Windows support.

If an in-tree backend is too much to carry, a lighter alternative is to link the fork from the docs only, for
example a short "Intel Gaudi2" section. I am happy with either; I would like your view before opening code PRs.

What do you do today instead?

I run the fork. It works, but it drifts further from main with every upstream release. Gaudi users cannot get it
through setup.py or the releases, and fixes in the shared server code reach it only by hand.

Originally created by @JChen-318 on GitHub (Oct 27, 2026). Original GitHub issue: https://github.com/Niko1221/Strata/issues/4323 ### Area [Engine] (speed, kernels, models, the server and API) ### What do you want to do? Run Strata on an **Intel Gaudi2** accelerator. Strata has no path for Gaudi today: the card is neither CUDA, HIP nor SYCL, and its compute engines (MME matrix units, TPC vector cores) are programmed through Habana's SynapseAI graph API and TPC-C kernels. I have a working backend for one Gaudi2 (HL-225, 96 GB HBM) in a fork, [JChen-318/gaudi2-single-card-strata](https://github.com/JChen-318/gaudi2-single-card-strata), based on `296b59d`. It keeps Strata's server, and only the engine underneath is new. **What runs today:** - Qwen3.8-Flash-Next IQ4_XS, fully resident in HBM, with a 262,144-token context. - A DFlash2 drafter for speculative decoding. - The measurements, raw data and limits are in the benchmark report PR #4322. - Prompt: 2,086 / 3,179 / 2,915 tok/s at 4K / 32K / 125K. - Decode: 105 / 114 / 106 tok/s. - Needles: 6/6 at 32k and 128k. **Question for the maintainers:** would you take this upstream as an **opt-in backend**? If yes, I would split it into focused PRs, in this order. 1. **`serve/`** (about 290 changed lines, tests included): recognise an `hpu` backend in the Monitor telemetry. - It reads `hl-smi` instead of `nvidia-smi`/`rocm-smi`. - The Monitor gets a prefill rate for engines that print only `PP n total ms`. - Nothing changes for the other backends. 2. **`hpu/`**, a self-contained directory with its own CMake project (`cmake -S hpu`). - The top-level CMake does not build it, so existing builds stay byte-identical. - About 550 files: the engine, about 110 TPC kernels, and CPU-side unit tests that run without the card. - It needs SynapseAI 1.24.x and `tpc-clang` from Habana's packages. A Docker image on Habana's base image is included. 3. **A docs page** (`docs/GAUDI2.md`) covering setup, the measured numbers and the limits. **Tradeoffs, as I see them:** - **Maintenance.** It is Gaudi-specific code: SynapseAI graphs and TPC-C kernels. Probably nobody else on the project has the hardware. I would maintain it, answer its issues, and run hardware validation before each change. - **CI.** It cannot be built without SynapseAI. A CI job could at most run the CPU-side unit tests, and only if the SDK headers were stubbed. - **Divergence.** The fork is about 2,400 commits behind `main`. The first step would be a rebase and re-validation on the card. - **Scope.** It supports one model family (Qwen3.8-Flash-Next geometry) on one card, and serves one request at a time. The first request at a new context size compiles its graphs (seconds), and the backend has no Windows support. If an in-tree backend is too much to carry, a lighter alternative is to link the fork from the docs only, for example a short "Intel Gaudi2" section. I am happy with either; I would like your view before opening code PRs. ### What do you do today instead? I run the fork. It works, but it drifts further from `main` with every upstream release. Gaudi users cannot get it through `setup.py` or the releases, and fixes in the shared server code reach it only by hand.
Author
Owner

@Niko1221 commented on GitHub (Nov 5, 2026):

Thanks for taking the time to report this.

Strata has changed a lot since this was opened, and 0.2.11 is out now, so many older reports no longer apply. We're closing issues older than a week that have had no new reports in the last week. Closed here does not mean rejected.

To reopen it takes about two minutes:

  1. Re-test on 0.2.11. It may already be fixed. Write down what you see.
  2. Start the title with its area: [Engine], [GUI], [TUI], [Benchmark], [Docs] or [Other].
  3. Fill in the parts of the issue form: what happened, the Strata version, your graphics card, memory and system.
  4. Comment /reopen. A check runs and either reopens the issue or lists what is still missing.

The rules are in CONTRIBUTING.md.

<!-- gh-comment-id:6660266381 --> @Niko1221 commented on GitHub (Nov 5, 2026): Thanks for taking the time to report this. Strata has changed a lot since this was opened, and 0.2.11 is out now, so many older reports no longer apply. We're closing issues older than a week that have had no new reports in the last week. Closed here does not mean rejected. To reopen it takes about two minutes: 1. Re-test on 0.2.11. It may already be fixed. Write down what you see. 2. Start the title with its area: [Engine], [GUI], [TUI], [Benchmark], [Docs] or [Other]. 3. Fill in the parts of the issue form: what happened, the Strata version, your graphics card, memory and system. 4. Comment `/reopen`. A check runs and either reopens the issue or lists what is still missing. The rules are in [CONTRIBUTING.md](https://github.com/Niko1221/Strata/blob/main/CONTRIBUTING.md).
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Niko1221/Strata#1907
No description provided.