OLD | NEW |
---|---|
1 /* | 1 /* |
2 * Copyright 2013 The LibYuv Project Authors. All rights reserved. | 2 * Copyright 2013 The LibYuv Project Authors. All rights reserved. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license | 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 | 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 | 6 * tree. An additional intellectual property rights grant can be found |
7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
9 */ | 9 */ |
10 | 10 |
11 #ifndef INCLUDE_LIBYUV_COMPARE_ROW_H_ // NOLINT | 11 #ifndef INCLUDE_LIBYUV_COMPARE_ROW_H_ // NOLINT |
12 #define INCLUDE_LIBYUV_COMPARE_ROW_H_ | 12 #define INCLUDE_LIBYUV_COMPARE_ROW_H_ |
13 | 13 |
14 #include "libyuv/basic_types.h" | 14 #include "libyuv/basic_types.h" |
15 | 15 |
16 #ifdef __cplusplus | 16 #ifdef __cplusplus |
17 namespace libyuv { | 17 namespace libyuv { |
18 extern "C" { | 18 extern "C" { |
19 #endif | 19 #endif |
20 | 20 |
21 #if defined(__pnacl__) || defined(__CLR_VER) || \ | 21 #if defined(__pnacl__) || defined(__CLR_VER) || \ |
22 (defined(__i386__) && !defined(__SSE2__)) | 22 (defined(__i386__) && !defined(__SSE2__)) |
23 #define LIBYUV_DISABLE_X86 | 23 #define LIBYUV_DISABLE_X86 |
24 #endif | 24 #endif |
25 // MemorySanitizer does not support assembly code yet. http://crbug.com/344505 | |
wtc1
2016/03/16 17:24:55
Frank: do you know whether it's just inline assemb
| |
26 #if defined(__has_feature) | |
27 #if __has_feature(memory_sanitizer) | |
28 #define LIBYUV_DISABLE_X86 | |
29 #endif | |
30 #endif | |
25 | 31 |
26 // Visual C 2012 required for AVX2. | 32 // Visual C 2012 required for AVX2. |
27 #if defined(_M_IX86) && !defined(__clang__) && \ | 33 #if defined(_M_IX86) && !defined(__clang__) && \ |
28 defined(_MSC_VER) && _MSC_VER >= 1700 | 34 defined(_MSC_VER) && _MSC_VER >= 1700 |
29 #define VISUALC_HAS_AVX2 1 | 35 #define VISUALC_HAS_AVX2 1 |
30 #endif // VisualStudio >= 2012 | 36 #endif // VisualStudio >= 2012 |
31 | 37 |
32 // clang >= 3.4.0 required for AVX2. | 38 // clang >= 3.4.0 required for AVX2. |
33 #if defined(__clang__) && (defined(__x86_64__) || defined(__i386__)) | 39 #if defined(__clang__) && (defined(__x86_64__) || defined(__i386__)) |
34 #if (__clang_major__ > 3) || (__clang_major__ == 3 && (__clang_minor__ >= 4)) | 40 #if (__clang_major__ > 3) || (__clang_major__ == 3 && (__clang_minor__ >= 4)) |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
69 uint32 HashDjb2_C(const uint8* src, int count, uint32 seed); | 75 uint32 HashDjb2_C(const uint8* src, int count, uint32 seed); |
70 uint32 HashDjb2_SSE41(const uint8* src, int count, uint32 seed); | 76 uint32 HashDjb2_SSE41(const uint8* src, int count, uint32 seed); |
71 uint32 HashDjb2_AVX2(const uint8* src, int count, uint32 seed); | 77 uint32 HashDjb2_AVX2(const uint8* src, int count, uint32 seed); |
72 | 78 |
73 #ifdef __cplusplus | 79 #ifdef __cplusplus |
74 } // extern "C" | 80 } // extern "C" |
75 } // namespace libyuv | 81 } // namespace libyuv |
76 #endif | 82 #endif |
77 | 83 |
78 #endif // INCLUDE_LIBYUV_COMPARE_ROW_H_ NOLINT | 84 #endif // INCLUDE_LIBYUV_COMPARE_ROW_H_ NOLINT |
OLD | NEW |