Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

xtheadvector tuple create insert and extract #127

Closed
nihui opened this issue Aug 27, 2024 · 2 comments · Fixed by #130
Closed

xtheadvector tuple create insert and extract #127

nihui opened this issue Aug 27, 2024 · 2 comments · Fixed by #130

Comments

@nihui
Copy link

nihui commented Aug 27, 2024

How to create one vfloat32m1x8_t from eight vfloat32m1_t ?
How to extract one vfloat32m1_t by tuple index from one vfloat32m1x8_t ?

There is no __riscv_vset_v_f32m1_f32m1x8 or __riscv_vget_v_f32m1_f32m1x8 intrinsics as stated in https://github.com/riscv-non-isa/rvv-intrinsic-doc/blob/v0.12.x/auto-generated/intrinsic_funcs/11_miscellaneous_vector_functions.md#vector-insertion-functions

I have tried v[0] or v.v0 but nothing magical happened

@nihui nihui changed the title xtheadvector tuple conversion xtheadvector tuple create insert and extract Aug 27, 2024
@imkiva
Copy link
Collaborator

imkiva commented Aug 28, 2024

The xtheadvector doesn't seem to have vget/vset on tuple types, as per https://occ-oss-prod.oss-cn-hangzhou.aliyuncs.com/resource/1836682/1638774209491/Xuantie+900+Series+RVV-0.7.1+Intrinsic+Manual.pdf page 898.

Will emulate these intrinsics, thanks for reporting ❤️

@nihui
Copy link
Author

nihui commented Aug 30, 2024

some tests from gcc 15 on master branch
gcc provides all the following intrinsics with -march=rv64gc_zfh_xtheadvector

__riscv_vcreate_v_f32m1x8
__riscv_vset_v_f32m1_f32m1x8
__riscv_vget_v_f32m1x8_f32m1

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 a pull request may close this issue.

2 participants