History

lavc/g722dsp: optimise R-V V apply_qmf

This stores the constant coefficients deinterleaved, so that they can be loaded directly with NF=0. Unfortunately, we cannot optimise loading the input, due to insufficient memory alignment (not 32-bit). Before: g722_apply_qmf_c: 82.5 g722_apply_qmf_rvv_i32: 78.2 After: g722_apply_qmf_c: 82.5 g722_apply_qmf_rvv_i32: 65.2

Rémi Denis-Courmont committed 2 years ago

Commit b88d4051 parent e33ce0d1 file · +13 −11Browse files

Showing the changes to libavcodec (1 of 1 file). Show all

Unified · Split

libavcodec/riscv/g722dsp_rvv.S+13−11
@@ -24,7 +24,9 @@ func ff_g722_apply_qmf_rvv, zve32x · 23 unmodified lines
24 lla t0, qmf_coeffs24 lla t0, qmf_coeffs
25 vsetivli zero, 12, e16, m2, ta, ma25 vsetivli zero, 12, e16, m2, ta, ma
26 vlseg2e16.v v28, (a0)26 vlseg2e16.v v28, (a0)
27 vlseg2e16.v v24, (t0)27 addi t1, t0, 12 * 2
28 vle16.v v24, (t0)
29 vle16.v v26, (t1)
28 vwmul.vv v16, v28, v2430 vwmul.vv v16, v28, v24
29 vwmul.vv v20, v30, v2631 vwmul.vv v20, v30, v26
30 vsetivli zero, 12, e32, m4, ta, ma32 vsetivli zero, 12, e32, m4, ta, ma
@@ -41,26 +43,26 @@ endfunc · 10 unmodified lines
41const qmf_coeffs, align=243const qmf_coeffs, align=2
42 .short 344 .short 3
43 .short -1145 .short -11
44 .short -11
45 .short 53
46 .short 1246 .short 12
47 .short -156
48 .short 3247 .short 32
49 .short 362
50 .short -21048 .short -210
51 .short -805
52 .short 95149 .short 951
53 .short 387650 .short 3876
54 .short 3876
55 .short 951
56 .short -80551 .short -805
57 .short -210
58 .short 36252 .short 362
59 .short 32
60 .short -15653 .short -156
61 .short 12
62 .short 5354 .short 53
63 .short -1155 .short -11
64 .short -1156 .short -11
57 .short 53
58 .short -156
59 .short 362
60 .short -805
61 .short 3876
62 .short 951
63 .short -210
64 .short 32
65 .short 12
66 .short -11
65 .short 367 .short 3
66endconst68endconst

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t