AMD-dteng
dcedd381bd
Merge branch 'dteng_flatmm_opt' of https://github.com/ROCm/composable_kernel into dteng_flatmm_opt
2025-06-18 20:13:51 -05:00
AMD-dteng
07b579d1dd
fix a bug that K_Warp_Tile not match in two files.
2025-06-18 19:51:57 -05:00
solin
fa9ccdfbdd
fix error
2025-06-18 09:55:51 +00:00
root
bb5a520324
Merge branch 'dteng_flatmm_opt' of https://github.com/ROCm/composable_kernel into dteng_flatmm_opt
2025-06-17 02:38:52 -05:00
root
a6f711de98
support even odd k in tail
2025-06-17 02:31:54 -05:00
solin
1fa6d41bee
add fp8 support for mi355
2025-06-03 13:30:50 +08:00
root
bd347831e0
compile IGLP work aroung
2025-05-30 00:58:56 -05:00
root
c097f90adf
first version
2025-05-26 04:45:18 -05:00
solin
c2d17ec24f
draft for 16*16*128 fp8
2025-05-14 09:56:13 +00:00
Illia Silin
58f9e9ffbc
Update the buffer load/store intrinsic names for clang>=20. ( #2192 )
...
* fix the buffer load/store intrinsic names
* fix clang format
2025-05-13 10:18:14 -07:00
Po Yen Chen
2920604786
[CK_TILE] Add logits soft-capping & customization support to the FMHA forward kernel/pipelines ( #2163 )
...
* hack for cap logits
* fix bug
* Re-format files
* Allow specifying logits_soft_cap through APIs
* Support turn on/off logits_soft_cap in async pipeline
* Do not generate non-verified kernels
* Align receipt used in Aiter
* Sync logits soft-capping across pipelines
* Re-enable some hdim pipelines
* fix perf
* Add attention variant for logits_soft_cap
* Add newline at end-of-file
* Fix performance
* Add comment to explain logits_soft_cap pre-processing
* Unify code
* Unify floating-point literal style
* Use class data member to slience the compilation error
* [CK_TILE] Update attention customizaton interface: add LogitsMask() (#2133 )
* Send 'mask' along with variant params to the LogitsMask()
* Send block indices to the variant
* Add indices parameters in variant interface
* Fix fmha bwd codegen error
* Allow switch logits_soft_cap impl
* Eliminate register spills
* Fix compilation errors
* Fix wrong LSE
* Fix LSE for splitkv kernel
* Sync splitkv pipeline changes
* Add batch_prefill kernel/pipeline
* Fix codegen error
* Undo changes in CMakeLists.txt
* Merge pipeline filtering check
* Use different code path if kHasLogitsSoftCap=false
* Remove [[maybe_unused]] attribute
* Use pre-existing compile-time flag to instantiate templates
* Sync pipeline changes
* Update CHANGELOG.md
---------
Co-authored-by: Bernard <bernaliu@amd.com >
Co-authored-by: coderfeli <coderfeli@163.com >
2025-05-13 12:19:25 +08:00
Thomas Ning
9d1e44e56a
Vectorized Transpose for Batched Transpose CK Tile Operator ( #2131 )
...
* Shared Memory for single data point
* CKTile Transpose vectorize CP1
* CKTile Transpose vectorize CP2
* CKTile Transpose vectorize CP2.1
* fixed the compile error of the transpose tile 2d
* Have the correct result for the current test sample
* Changes to printing tensor
* fp8 support added
* Debugging for transpose
* solving the corner issue
* Changed padding flag
* Intermideate Debugging
* Intermidiate Debugging
* Intermediate Debugging
* Finished debugging of the transpose op
* Code Cleanup
* Adding edge case smoke tests
* Adding Transpose test to CI/CD
* Adding Transpose test to CI/CD
* Adding Transpose test to CI/CD
* Addressing Review Comment
* Addressing Comments
* Addressing Comments
* Measuring Perf Tests
* Code Cleanup
* Changlog
* Added the running iterations
* clang format
* Fix the changelog
* Fix the compilation error
* change the printing factor
---------
Co-authored-by: ThruptiRajLakshmanaGowda <tlakshma@amd.com >
2025-05-12 00:41:45 -07:00
BingYuan.Zhou
6a3960c1e1
Flatmm merge ( #2168 )
...
* sync with function interface of cshuffleepiloge,fix flatmm build fail
* move code from solin/flatmm which add mfma16*16*32fp8 and optimize flatmm
---------
Co-authored-by: solin <bingzhou@amd.com >
2025-05-08 12:59:57 +08:00
Khushbu Agarwal
c7b8e86e34
[CK_Tile] Simplified Mem pipeline ( #2159 )
...
* simplify code
* compiled the code
* Simplified example and codegen for mem pipeline
* Reveting config and universal gemm example
* clang formatted
* remove comments
* clang formatted
* Add memory operation changes for defualt pipeline
* fix config file
---------
Co-authored-by: ThomasNing <thomas.ning@amd.com >
2025-05-07 18:37:31 -07:00
kylasa
956fe8f751
Simple copy kernel, which can be a tool to experiment with CK_Tile API with minimal code. ( #2156 )
...
* Test Copy kernel code for testing tile distribution logic
* Fix the error
* Solved the problem
* Updated comments and document formatting
* Removed unused tile distribution and code cleanup
* Added README.md and formatting for CI/CD.
---------
Co-authored-by: ThomasNing <thomas.ning@amd.com >
2025-05-07 00:02:59 -07:00
carlushuang
4e9b76f88c
[CK_TILE] optimize moe sorting kernel, boost large context case up to 20x ( #2153 )
...
* combine 2-3 as single stage
* support zeroing
* improve long tokens
* update specialization
* b16 ws
* 8bit topk optimize
* update 15 example
2025-05-06 17:32:07 +08:00
jakpiase
0bcb804ad0
[CK_TILE] Remove scratch usage from universal gemm ( #2001 )
...
* moves kbatch condition outside of kernel
* add reviewer comments
* fixes
* fix tests
* fixes after review
---------
Co-authored-by: Adam Osewski <19374865+aosewski@users.noreply.github.com >
2025-05-05 18:46:44 +02:00
Illia Silin
9a9f59ae69
Revert "Add ck tile examples to package ( #1880 )" ( #2150 )
2025-04-30 10:20:16 -07:00
jakpiase
434d19f696
Add ck tile examples to package ( #1880 )
...
* add ck tile examples to package
* Update jenkinsfile
* fix for jenkinsfile
* fix for building ck tile code on non gfx9
* compile ck tile examples only for gfx94
* include ck tile examples in all target
* fix for basic gemm UseStructuredSparsity
* Update CMakeLists.txt
* Update gemm_pipeline_problem.hpp
* add targets to rocm install
---------
Co-authored-by: Illia Silin <98187287+illsilin@users.noreply.github.com >
2025-04-28 09:53:19 -07:00
Yi DING
8add2cf45d
Fix fp8 convert & add option for basic example ( #2129 )
2025-04-27 16:26:05 -07:00
Po Yen Chen
3d4d70d2fc
Avoid using store_tile_raw() for fp32 tensors ( #2072 )
2025-04-26 23:07:41 -07:00
joyeamd
41541aff7a
SWDEV-52596 for hdim=256, when use splitkv pipeline, two new pipelines need to be added ( #2126 )
2025-04-25 16:31:09 +08:00
rocking
02ce6d39ea
Only generate specific hdim ( #2120 )
2025-04-24 18:52:58 +08:00
Gino Lu
504f563f78
[CK-Tile] warp-gemm support for using V_MFMA_F32_16x16x32_BF16 ( #2073 )
...
* draft v_mfma_f32_16x16x32_bf16
* fix error config and add debug code.
* Solve the CShuffle Problem
* draft v_mfma_f32_16x16x32_bf16
* fix error config and add debug code.
* Solve the CShuffle Problem
* fix error while testing new command
* Finished the feature of new mfma 16*16*32
* Addressed the comment
---------
Co-authored-by: ThomasNing <thomas.ning@amd.com >
2025-04-22 15:52:36 -07:00
BingYuan.Zhou
eaf1f0bf3b
[flatmm] implement basic fp16 flatmm ( #2089 )
...
* [flatmm] implement basic fp16 flatmm
* fix CI build fail
---------
Co-authored-by: root <root@hjbog-srdc-50.amd.com >
Co-authored-by: solin <bingzhou@amd.com >
2025-04-16 16:51:17 +08:00
joyeamd
94d47b1680
fmha hdim256 vectorize improve ( #2086 )
...
For hdim 256, will not have vectorized buffer load when seqlen % 256 != 0 and hdim % 256 = 0; this commit tries to solve this condition.
2025-04-16 09:21:04 +08:00
jakpiase
6c61f4d237
[CK_TILE] Add 2:4 structured sparsity support for fp16 gemm ( #1957 )
...
* add structured sparsity fp16 support for gemm
* added reviewer suggestions
* update changelog
* update changelog
* add reviewers suggestions
* Minor fix
* clang fix
* fix doxygen
2025-04-11 12:18:26 +02:00
slippedJim
5f885d2b7a
add fmha fwd splitkv receipt for aiter c++ api ( #2068 )
...
* add s_randval for c++ api
* Fix bug of bias in splitkv
---------
Co-authored-by: rocking <ChunYu.Lai@amd.com >
2025-04-10 23:21:13 +08:00
slippedJim
5a22b61de5
Add new receipt ( #2055 )
2025-04-07 14:18:01 +08:00
Thomas Ning
50d1f8ff90
Add the MI355 support for CK TILE GEMM ( #2046 )
...
* Get the root cause of the ck tile gemm failing on mi355
* Fix the ck tile gemm on MI355
* delete the debug info
2025-04-03 11:48:54 -07:00
rocking
8a20b62e91
Reduce redundant space in bias tensor ( #2024 )
...
Co-authored-by: Po Yen Chen <PoYen.Chen@amd.com >
2025-03-28 21:58:06 +08:00
felix
a82f338fb9
hotfix fix sorting int64 ( #2025 )
...
* fix sorting int64
* clang format
* fix example issue
* update WA issue #
---------
Co-authored-by: coderfeli <coderfeli@163.com >
Co-authored-by: carlushuang <carlus.huang@amd.com >
2025-03-28 11:31:52 +08:00
ruanjm
d49abdaa87
[CK_TILE] Improve RMS/Layer Normalization 2 Pass Pipeline Performance ( #1861 )
...
* 50ms -> 28ms
* Fix bug in non fuse_add_store cases
* Fine tuned setting for 2 pass pipeline
* adjust workload
* remove unnecessary change
* add layernorm
* Adding output quant and unquant results at the same time.
* fix test
* fix format
* tune for cases 128x640 and 128x1024
* bug ifx
2025-03-25 20:09:45 +08:00
carlushuang
6c08c5c46d
add mask support in hdim=192/128 ( #1999 )
2025-03-21 18:28:43 +08:00
BingYuan.Zhou
5a0d693b86
fix ck_tile/basic_gemm build error ( #1988 )
2025-03-20 22:01:14 -07:00
carlushuang
e3c9886cdf
[CK_TILE] return value with macro in ck_tile::kernel_launch API ( #1982 )
...
* return value with macro and revert the return value
* [CK-TILE] no-macro launch api solution (#1992 )
* no-macro solution
* address -Wcomma
---------
Co-authored-by: Max Podkorytov <4273004+tenpercent@users.noreply.github.com >
2025-03-20 11:00:29 -07:00
jakpiase
0e91d32c61
[CK_TILE] Switch to universal gemm for batched and grouped gemms ( #1919 )
...
* switch to universal gemm for batched and grouped gemms
* added reviewer comments
* fixed grouped gemm tests
2025-03-20 11:17:04 +01:00
rocking
b819c217e4
Sync the kname with instance name ( #1989 )
...
Co-authored-by: Po Yen Chen <PoYen.Chen@amd.com >
2025-03-20 00:06:45 +08:00
valarLip
52b1cd7780
hotfix fmoe build issue ( #1976 )
2025-03-13 15:11:59 +08:00
carlushuang
3e81279d26
Reapply "[CK_TILE] support hdim=192/128 pair for deepseekv3 ( #1961 )" … ( #1971 )
...
* Reapply "[CK_TILE] support hdim=192/128 pair for deepseekv3 (#1961 )" (#1969 )
This reverts commit 8cbcd3e0d0 .
* fix codegen problem
* Update config.hpp
---------
Co-authored-by: Illia Silin <98187287+illsilin@users.noreply.github.com >
2025-03-13 11:41:39 +08:00
Illia Silin
8cbcd3e0d0
Revert "[CK_TILE] support hdim=192/128 pair for deepseekv3 ( #1961 )" ( #1969 )
...
This reverts commit 7a93b16ff6 .
2025-03-11 10:40:18 -07:00
carlushuang
7a93b16ff6
[CK_TILE] support hdim=192/128 pair for deepseekv3 ( #1961 )
...
* support hdim=192/128 pair
* remove useless print
* update
2025-03-11 21:07:40 +08:00
Max Podkorytov
9e132eb77c
refactor ck-tile kernel launch ( #1925 )
2025-03-07 08:29:40 -08:00
kylasa
66c5f5b0b6
Addressing (Post Merge) code review comments for PR 1845 ( #1883 )
...
* Addressing code review comments.
* Addressing code review comments.
* Reorganized code for better readability.
* add ck_tile gemms for new types in CI
* fix jenkins syntax
* fix script syntax
* Add the test cases back
* Address the review comments
* Address review comments
* clang format
* Solve the merging issues
* Addressed the comments
* clang format
---------
Co-authored-by: illsilin <Illia.Silin@amd.com >
Co-authored-by: ThomasNing <thomas.ning@amd.com >
Co-authored-by: Adam Osewski <19374865+aosewski@users.noreply.github.com >
2025-03-06 11:40:30 -08:00
Illia Silin
9b51c08bf7
remove support for gfx940 and gfx941 targets ( #1944 )
...
* remove support for gfx940 and gfx941 targets
* update changelog
2025-03-05 11:07:33 -08:00
rocking
faa2235dad
explicit show no feature in kernel name ( #1920 )
2025-02-28 14:23:30 +08:00
slippedJim
a9bcd3c98d
make fmha bwd api template for v2 & v3 ( #1918 )
...
* use template fmha_bwd function
* update
---------
Co-authored-by: Po Yen Chen <PoYen.Chen@amd.com >
2025-02-27 19:26:19 +08:00
Bartłomiej Kocot
0356ee069e
[CK TILE] Gemm pk_int4_t permute B ( #1907 )
...
* [CK TILE] Gemm pk_int4_t permute B
* Fixes
2025-02-27 11:01:14 +01:00
rocking
e9ee568681
Apply filter to every kernel in the codgen of FMHA ( #1911 )
...
* add receipt for fwd
* Add receipt for bwd
* Use kernel name to avoid more receipt
* apply filter to every kernel
2025-02-26 20:20:29 +08:00
carlushuang
353a612b44
[CK_TILE] add moe-sorting MP kernel ( #1910 )
...
* moe sorting ex
* fix bug for race condition
* fix bug and optimze large expert
* fix
* optimize with sub_token_oneshot
* support skip empty tokens for expert sorting
* update moe_sorting
* tidy code
* support mp kernel
* hint mp
* remove use less code
* porting to example 15
---------
Co-authored-by: valarLip <340077269@qq.com >
2025-02-25 17:56:55 +08:00