This RFC started with a simple question: how should a downstream kernel library consume kernels written in FlyDSL?
After implementing RMSNorm backward and studying both Quack and AITER, the main issue is no longer kernel capability. It is ownership.
FlyDSL now has RMSNorm forward + backward, residual backward, autograd coverage, and an optimized staged-reduction path (#795, #800, #855). The current backward implementation is competitive with the tested PyTorch and AIter baselines on MI355X.
The remaining question is where production kernel code and integration logic should live.
Proposed boundary
Follow the model already used by AITER:
FlyDSL owns
- the DSL, compiler, and runtime;
- target selection, JIT cache correctness, device/context safety, streams, and diagnostics;
- generic infrastructure that is useful to more than one downstream.
The downstream library owns
- the production FlyDSL kernel used by that library;
- operator semantics, dtype support, autograd, framework custom ops, fallback behavior, and dispatch;
- operator-specific tuning, tests, benchmarks, packaging, and CI.
This keeps one semantic owner for each operator. It also avoids turning FlyDSL into an operator library just so Quack can import one RMSNorm implementation. Quack can adapt the existing Apache-2.0 FlyDSL kernel with attribution and then evolve it with Quack's API.
Quack RMSNorm PoC
The scope question is now open in Dao-AILab/quack#178. We should not open implementation sub-issues until Quack maintainers confirm that a non-CuTe backend belongs in the project.
If accepted, the work should be split into small Quack-owned changes:
- Isolate eager CuTe/CUDA imports and decide how CUDA/ROCm dependencies are installed.
- Add an explicit experimental FlyDSL RMSNorm entry point.
- Implement plain weighted forward + backward first, including FP16/BF16/FP32 inputs, FP32 weights for 16-bit inputs, runtime
eps, and flattenable contiguous inputs.
- Validate on gfx942 and gfx950 against Quack's references and ROCm PyTorch/AIter.
- Enable transparent
quack.rmsnorm dispatch only after the agreed API and torch.compile contract are covered.
Bias, residual/prenorm, per-head mode, output dtype conversion, optional weight, and weight_offset are follow-ups owned by Quack—not reasons to expand FlyDSL's public operator surface.
FlyDSL work
Only one required FlyDSL-core gap has been identified:
- #878: resolve the JIT target from the invocation device and keep target/cache reuse safe across GPU architectures.
The existing torch.compile discussion in #596 may still lead to a useful generic helper, but it is not a blocker for the Quack PoC. Quack and AITER already own operator-specific custom-op wrappers.
The RMSNorm training tracker #769 is complete and closed. Generic autotune work remains in #770, but Quack-specific search spaces and selected configs should live in Quack.
Decision
For this RFC, the proposed direction is:
This RFC started with a simple question: how should a downstream kernel library consume kernels written in FlyDSL?
After implementing RMSNorm backward and studying both Quack and AITER, the main issue is no longer kernel capability. It is ownership.
FlyDSL now has RMSNorm forward + backward, residual backward, autograd coverage, and an optimized staged-reduction path (#795, #800, #855). The current backward implementation is competitive with the tested PyTorch and AIter baselines on MI355X.
The remaining question is where production kernel code and integration logic should live.
Proposed boundary
Follow the model already used by AITER:
FlyDSL owns
The downstream library owns
This keeps one semantic owner for each operator. It also avoids turning FlyDSL into an operator library just so Quack can import one RMSNorm implementation. Quack can adapt the existing Apache-2.0 FlyDSL kernel with attribution and then evolve it with Quack's API.
Quack RMSNorm PoC
The scope question is now open in Dao-AILab/quack#178. We should not open implementation sub-issues until Quack maintainers confirm that a non-CuTe backend belongs in the project.
If accepted, the work should be split into small Quack-owned changes:
eps, and flattenable contiguous inputs.quack.rmsnormdispatch only after the agreed API andtorch.compilecontract are covered.Bias, residual/prenorm, per-head mode, output dtype conversion, optional weight, and
weight_offsetare follow-ups owned by Quack—not reasons to expand FlyDSL's public operator surface.FlyDSL work
Only one required FlyDSL-core gap has been identified:
The existing
torch.compilediscussion in #596 may still lead to a useful generic helper, but it is not a blocker for the Quack PoC. Quack and AITER already own operator-specific custom-op wrappers.The RMSNorm training tracker #769 is complete and closed. Generic autotune work remains in #770, but Quack-specific search spaces and selected configs should live in Quack.
Decision
For this RFC, the proposed direction is: