Skip to content

Fix/fly opt gpu llvm translations#503

Open
Peter9606 wants to merge 2 commits intoROCm:mainfrom
Deep-Spark:fix/fly-opt-gpu-llvm-translations
Open

Fix/fly opt gpu llvm translations#503
Peter9606 wants to merge 2 commits intoROCm:mainfrom
Deep-Spark:fix/fly-opt-gpu-llvm-translations

Conversation

@Peter9606
Copy link
Copy Markdown
Contributor

Summary

  • Add a fly-opt regression smoke test that exercises the real gpu-module-to-binary path on a minimal gpu.module.
  • Register GPU-to-LLVMIR translation interfaces in fly-opt, matching the requirements of MLIR GPU binary serialization.
  • Link MLIRToLLVMIRTranslationRegistration so the translation registration symbols are available.

Motivation

fly-opt currently registers MLIR dialects, extensions, and passes, but not the GPU-to-LLVMIR translation interfaces required by gpu-module-to-binary.

As a result, running binary codegen through fly-opt can fail before target serialization with:

missing LLVMTranslationDialectInterface registration for dialect for op: gpu.module

Test Plan

FLYDSL_FLY_OPT=/tmp/flydsl-iluvatar-runtime-smoke/bin/fly-opt \
  python3 -m pytest tests/unit/test_fly_opt_tooling.py -q --confcutdir=tests/unit
Result:

1 passed
When no fly-opt binary is available, the test skips unless FLYDSL_FLY_OPT or FLY_OPT points to a built binary.

Peter9606 added 2 commits May 11, 2026 16:29
Signed-off-by: Fujun Han <fujun.han@iluvatar.com>
Signed-off-by: Fujun Han <fujun.han@iluvatar.com>
@Peter9606
Copy link
Copy Markdown
Contributor Author

Could @coderfeli please take a look at this PR? This fixes a generic fly-opt registration gap exposed by gpu-module-to-binary, and I would appreciate a review on whether this is the right place to register the GPU-to-LLVMIR translations.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant