comparison libgsmefr/memops.h @ 58:d285877fc4cc

libgsmefr: cod_12k2.c compiles
author Mychaela Falconia <falcon@freecalypso.org>
date Fri, 25 Nov 2022 18:50:50 +0000
parents
children
comparison
equal deleted inserted replaced
57:e005e7b91f3c 58:d285877fc4cc
1 /*
2 * The original code from ETSI uses its own Copy() and Set_zero()
3 * functions, operating on Word16 elements. Here we implement them
4 * as static inline functions wrapping around memcpy and memset.
5 */
6
7 #include <string.h>
8
9 static inline void Copy (
10 const Word16 x[], /* (i) : input vector */
11 Word16 y[], /* (o) : output vector */
12 Word16 L /* (i) : vector length */
13 )
14 {
15 memcpy(y, x, L * 2);
16 }
17
18 static inline void Set_zero (
19 Word16 x[], /* (o) : vector to clear */
20 Word16 L /* (i) : length of vector */
21 )
22 {
23 memset(x, 0, L * 2);
24 }