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

Add RISC-V and RVV1.0 support into library #1

Open
wants to merge 28 commits into
base: dev
Choose a base branch
from

Conversation

suvorovrain
Copy link

Implement support of RISC-V architecture and RVV1.0 RISC-V vector extension into library.
Add saxpy function that uses RVV1.0 instruction set.

@suvorovrain
Copy link
Author

Also add RISC-V support in CMake with cpu_features

Copy link
Member

@gsvgit gsvgit left a comment

Choose a reason for hiding this comment

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

Is there documentation where information about RVV support should be added?

@@ -131,6 +131,7 @@ typedef struct

bool cpu_features_avx2 ; // x86_64 with AVX2
bool cpu_features_avx512f ; // x86_64 with AVX512f
bool cpu_features_rvv ; // RISC-V with RVV1.0
Copy link
Member

Choose a reason for hiding this comment

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

Should it be cpu_features_rvv_1_0 or something else to note that it may be incompatible with 0.7 ?

@suvorovrain
Copy link
Author

Is there documentation where information about RVV support should be added?

I haven't found it. So I've searched for every part of code in library where was implemented AVX support and add RVV following the example of how AVX support was done


#if GB_COMPILER_SUPPORTS_RVV1

GB_TARGET_AVX2 static inline void GB_AxB_saxpy5_unrolled_rvv
Copy link

Choose a reason for hiding this comment

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

Is GB_TARGET_AVX2 the correct macro?


CPU_FEATURES_END_CPP_NAMESPACE

#endif // CPU_FEATURES_INCLUDE_CPUINFO_RISCV_H_
Copy link

Choose a reason for hiding this comment

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

New line character is forgotten

}

#endif // defined(CPU_FEATURES_OS_LINUX) || defined(CPU_FEATURES_OS_ANDROID)
#endif // CPU_FEATURES_ARCH_RISCV
Copy link

Choose a reason for hiding this comment

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

New line character is forgotten

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.

3 participants