mirror of
https://chromium.googlesource.com/libyuv/libyuv
synced 2025-12-06 08:46:47 +08:00
Support RVV v0.12 intrinsics for row_rvv.cc & scale_rvv.cc
1. Add two defined marco LIBYUV_RVV_HAS_TUPLE_TYPE & LIBYUV_RVV_HAS_VXRM_ARG Intrinsic v0.12 introduces - tuple type in segment load & store - vxrm argument in fixed-point intrinsics (e.g vnclip) These two marcos are controled by __riscv_v_intrinsic. 2. Support RVV v0.12 intrinsics in row_rvv.cc & scale_rvv.cc Change-Id: I921f91d9dc8fdda031e7b6647d0e296aa2793c39 Signed-off-by: Bruce Lai <bruce.lai@sifive.com> Reviewed-on: https://chromium-review.googlesource.com/c/libyuv/libyuv/+/4767120 Reviewed-by: Frank Barchard <fbarchard@chromium.org>
This commit is contained in:
parent
5adc2ce2cb
commit
7758c961c5
@ -841,8 +841,15 @@ extern "C" {
|
||||
#endif
|
||||
|
||||
#if !defined(LIBYUV_DISABLE_RVV) && defined(__riscv_vector)
|
||||
#if __riscv_v_intrinsic > 11000
|
||||
// Since v0.12, TUPLE_TYPE is introduced for segment load and store.
|
||||
#define LIBYUV_RVV_HAS_TUPLE_TYPE
|
||||
// Since v0.12, VXRM(fixed-point rounding mode) is included in arguments of
|
||||
// fixed-point intrinsics.
|
||||
#define LIBYUV_RVV_HAS_VXRM_ARG
|
||||
#endif
|
||||
|
||||
#define HAS_COPYROW_RVV
|
||||
#if __riscv_v_intrinsic == 11000
|
||||
#define HAS_AB64TOARGBROW_RVV
|
||||
#define HAS_ABGRTOYJROW_RVV
|
||||
#define HAS_ABGRTOYROW_RVV
|
||||
@ -900,7 +907,6 @@ extern "C" {
|
||||
#define HAS_SPLITUVROW_RVV
|
||||
#define HAS_SPLITXRGBROW_RVV
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#if defined(_MSC_VER) && !defined(__CLR_VER) && !defined(__clang__)
|
||||
#if defined(VISUALC_HAS_AVX2)
|
||||
|
||||
@ -184,7 +184,6 @@ extern "C" {
|
||||
// #define HAS_SCALEARGBROWDOWNEVEN_RVV
|
||||
#define HAS_SCALEUVROWDOWN4_RVV
|
||||
#define HAS_SCALEUVROWDOWNEVEN_RVV
|
||||
#if __riscv_v_intrinsic == 11000
|
||||
#define HAS_SCALEARGBROWDOWN2_RVV
|
||||
#define HAS_SCALEARGBROWDOWN2BOX_RVV
|
||||
#define HAS_SCALEARGBROWDOWN2LINEAR_RVV
|
||||
@ -208,7 +207,6 @@ extern "C" {
|
||||
#define HAS_SCALEUVROWUP2_BILINEAR_RVV
|
||||
#define HAS_SCALEUVROWUP2_LINEAR_RVV
|
||||
#endif
|
||||
#endif
|
||||
|
||||
// Scale ARGB vertically with bilinear interpolation.
|
||||
void ScalePlaneVertical(int src_height,
|
||||
|
||||
@ -43,6 +43,7 @@ if(RISCV_COMPILER_FLAGS STREQUAL "")
|
||||
list(APPEND RISCV_COMPILER_FLAGS "-march=rv64gc")
|
||||
endif()
|
||||
endif()
|
||||
add_compile_options("-Wuninitialized")
|
||||
message(STATUS "RISCV_COMPILER_FLAGS: ${RISCV_COMPILER_FLAGS}")
|
||||
|
||||
set(CMAKE_C_FLAGS "${RISCV_COMPILER_FLAGS} ${CMAKE_C_FLAGS}")
|
||||
|
||||
1212
source/row_rvv.cc
1212
source/row_rvv.cc
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
Loading…
x
Reference in New Issue
Block a user