• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  *  Copyright (c) 2015 The WebM project authors. All Rights Reserved.
3  *
4  *  Use of this source code is governed by a BSD-style license
5  *  that can be found in the LICENSE file in the root of the source
6  *  tree. An additional intellectual property rights grant can be found
7  *  in the file PATENTS.  All contributing project authors may
8  *  be found in the AUTHORS file in the root of the source tree.
9  */
10 
11 #ifndef VPX_VPX_DSP_X86_TXFM_COMMON_SSE2_H_
12 #define VPX_VPX_DSP_X86_TXFM_COMMON_SSE2_H_
13 
14 #include <emmintrin.h>
15 #include "vpx/vpx_integer.h"
16 
17 #define pair_set_epi16(a, b)                                            \
18   _mm_set_epi16((int16_t)(b), (int16_t)(a), (int16_t)(b), (int16_t)(a), \
19                 (int16_t)(b), (int16_t)(a), (int16_t)(b), (int16_t)(a))
20 
21 #define pair_set_epi32(a, b) \
22   _mm_set_epi32((int)(b), (int)(a), (int)(b), (int)(a))
23 
24 #define dual_set_epi16(a, b)                                            \
25   _mm_set_epi16((int16_t)(b), (int16_t)(b), (int16_t)(b), (int16_t)(b), \
26                 (int16_t)(a), (int16_t)(a), (int16_t)(a), (int16_t)(a))
27 
28 #define octa_set_epi16(a, b, c, d, e, f, g, h)                           \
29   _mm_setr_epi16((int16_t)(a), (int16_t)(b), (int16_t)(c), (int16_t)(d), \
30                  (int16_t)(e), (int16_t)(f), (int16_t)(g), (int16_t)(h))
31 
32 #endif  // VPX_VPX_DSP_X86_TXFM_COMMON_SSE2_H_
33