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

riscv: add rvv support #102

Open
wants to merge 5 commits into
base: master
Choose a base branch
from
Open

riscv: add rvv support #102

wants to merge 5 commits into from

Conversation

Ag-Cu
Copy link

@Ag-Cu Ag-Cu commented Feb 17, 2025

Summary

This pull request introduces support for the RISC-V Vector Extension (RVV) with 128-bit vector size in the sonic-cpp library.

Key Changes

CMake Configuration:

Added a new build option ENABLE_RVV_128 to enable RVV support.
Updated set_arch_flags.cmake to include RVV-specific compile options.

RVV-Specific Implementations:

Added RVV-specific architecture files under include/sonic/internal/arch/rvv-128/.
Implemented various SIMD operations for RVV, including string processing, integer conversion, and JSON quoting.

Test Results

[----------] Global test environment tear-down
[==========] 175 tests from 25 test suites ran. (43717 ms total)
[  PASSED  ] 175 tests.

[email protected] and others added 5 commits February 17, 2025 09:58
The build failed due to missing <algorithm> header when using std::remove
in the C++17 test section. The compiler incorrectly resolved to the C
library remove() function instead of STL algorithm.

This change:
1. Adds explicit #include <algorithm> for STL algorithms

Fixes compilation error:
error: cannot convert 'ValueIterator' to 'const char*'
note: initializing argument 1 of 'int remove(const char*)'
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.

1 participant