[KernelGen][MThreads] Add erfinv Moore Threads specialized operator - #249
Conversation
|
/test | erfinv:mthreads |
|
Dongxu-H
left a comment
There was a problem hiding this comment.
MThreads backend CI failed: backend-tests (mthreads-musa520) / test conclusion is failure. This is a MThreads backend specialized implementation and must pass MThreads CI before merge.
|
/test | erfinv:mthreads |
❌ On-demand test failedOperator: The test failed to complete. Check the workflow run for details. |
Dongxu-H
left a comment
There was a problem hiding this comment.
PR contains large infrastructure changes (removing CODEOWNERS, modifying workflows, adding image-builder and sync-to-kernelgen workflows) that should not be mixed with operator implementation. Infrastructure changes should be submitted as separate PR. Only operator-specific changes should remain: src/flag_gems/runtime/backend/_mthreads/ops/erfinv.py.
|
/test | erfinv:mthreads |
1 similar comment
|
/test | erfinv:mthreads |
|
/test | erfinv:mthreads |
1 similar comment
|
/test | erfinv:mthreads |
d6d779e to
4e613f5
Compare
Dongxu-H
left a comment
There was a problem hiding this comment.
Mthreads backend CI 失败,必须修复。
_erfinv 函数与 PR 250 完全相同,应该提取到共享模块避免代码重复。
Dongxu-H
left a comment
There was a problem hiding this comment.
CI backend-tests (mthreads-musa520) failed. Backend-specific implementation must pass corresponding backend CI.
The erfinv helper function in erfinv.py is identical to erfinv.py. Consider extracting it to a shared module to avoid code duplication.
[KernelGen][MThreads] Add erfinv Moore Threads specialized operator
Summary
Add a Moore Threads (MUSA) specialized Triton kernel for
erfinv, overriding the generic implementation viaruntime.replace_customized_ops(). The kernel evaluates the inverse error function in fp32 using an inlined rational polynomial approximation (the libdeviceerfinvintrinsic crashes the MThreadsllcbackend), with autotuned block/vector sizes.Testing
tests/test_erfinv_.py(-m erfinv)GEMS_MTHREADS ERFINVdebug logPerformance
Compared against the generic FlagGems implementation on Moore Threads (MUSA).
erfinv
Files Changed
src/flag_gems/runtime/backend/_mthreads/ops/erfinv.py: Moore Threads Triton kernel + fallbacksrc/flag_gems/runtime/backend/_mthreads/ops/__init__.py: Register import and__all__