Skip to content

[RVV] add rvv support for f16-vcmul#9971

Open
ken-unger wants to merge 6 commits intogoogle:masterfrom
ken-unger:f16-vcmul-rvv
Open

[RVV] add rvv support for f16-vcmul#9971
ken-unger wants to merge 6 commits intogoogle:masterfrom
ken-unger:f16-vcmul-rvv

Conversation

@ken-unger
Copy link
Copy Markdown
Contributor

simple addition of rvv kernel for f16-vcmul, which enables subgraph/rope-test for FP16

BPI-F3 (K1)
f16_vcmul/xnn_f16_vcmul_ukernel__rvvfp16arith_u1v/N:1920/real_time        1921 ns         1899 ns       363553 bytes=11.9965G/s cpufreq=1.6G num_elements=0.999705G/s
f16_vcmul/xnn_f16_vcmul_ukernel__rvvfp16arith_u1v/N:21120/real_time      33737 ns        33581 ns        20740 bytes=7.51224G/s cpufreq=1.6G num_elements=626.02M/s
f16_vcmul/xnn_f16_vcmul_ukernel__rvvfp16arith_u2v/N:1920/real_time        1353 ns         1348 ns       516312 bytes=17.0232G/s cpufreq=1.6G num_elements=1.4186G/s
f16_vcmul/xnn_f16_vcmul_ukernel__rvvfp16arith_u2v/N:21120/real_time      32855 ns        32654 ns        21395 bytes=7.71382G/s cpufreq=1.6G num_elements=642.818M/s
f16_vcmul/xnn_f16_vcmul_ukernel__rvvfp16arith_u4v/N:1920/real_time        1382 ns         1377 ns       506017 bytes=16.6657G/s cpufreq=1.6G num_elements=1.38881G/s
f16_vcmul/xnn_f16_vcmul_ukernel__rvvfp16arith_u4v/N:21120/real_time      40077 ns        39915 ns        13681 bytes=6.32378G/s cpufreq=1.6G num_elements=526.982M/s

Comment thread src/configs/cmul-config.c
Comment thread src/configs/cmul-config.c
#endif
}
XNN_INIT_ONCE(f16_cmul);
return f16_cmul_config.ukernel ? &f16_cmul_config : NULL;
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@dsharletg I modified this (line 87) to protect against the unconfigured ukernel case. (Sorry it seems your previous comments here have been dropped).

@dsharlet
Copy link
Copy Markdown
Collaborator

This branch has conflicts, can you please merge it?

@ken-unger
Copy link
Copy Markdown
Contributor Author

I've updated to latest master. Should be good to go now.

copybara-service Bot pushed a commit that referenced this pull request Apr 30, 2026
--
0cd97f2 by Ken Unger <ken.j.unger@gmail.com>:

add rvv support for f16-vcmul

--
1f8d093 by Ken Unger <ken.j.unger@gmail.com>:

add rvv support for f16-vcmul

--
64d21ff by Ken Unger <ken.j.unger@gmail.com>:

handle unconfigured f16-vcmul kernel

--
8b3bda4 by Ken Unger <ken.j.unger@gmail.com>:

update-microkernels

FUTURE_COPYBARA_INTEGRATE_REVIEW=#9971 from ken-unger:f16-vcmul-rvv 8b3bda4
PiperOrigin-RevId: 907284990
copybara-service Bot pushed a commit that referenced this pull request Apr 30, 2026
--
0cd97f2 by Ken Unger <ken.j.unger@gmail.com>:

add rvv support for f16-vcmul

--
1f8d093 by Ken Unger <ken.j.unger@gmail.com>:

add rvv support for f16-vcmul

--
64d21ff by Ken Unger <ken.j.unger@gmail.com>:

handle unconfigured f16-vcmul kernel

--
8b3bda4 by Ken Unger <ken.j.unger@gmail.com>:

update-microkernels

FUTURE_COPYBARA_INTEGRATE_REVIEW=#9971 from ken-unger:f16-vcmul-rvv 8b3bda4
PiperOrigin-RevId: 907284990
copybara-service Bot pushed a commit that referenced this pull request May 1, 2026
--
0cd97f2 by Ken Unger <ken.j.unger@gmail.com>:

add rvv support for f16-vcmul

--
1f8d093 by Ken Unger <ken.j.unger@gmail.com>:

add rvv support for f16-vcmul

--
64d21ff by Ken Unger <ken.j.unger@gmail.com>:

handle unconfigured f16-vcmul kernel

--
8b3bda4 by Ken Unger <ken.j.unger@gmail.com>:

update-microkernels

FUTURE_COPYBARA_INTEGRATE_REVIEW=#9971 from ken-unger:f16-vcmul-rvv 3659dcf
PiperOrigin-RevId: 907284990
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.

2 participants