OLD | NEW |
---|---|
1 /* | 1 /* |
2 * Copyright 2014 The Android Open Source Project | 2 * Copyright 2014 The Android Open Source Project |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license that can be | 4 * Use of this source code is governed by a BSD-style license that can be |
5 * found in the LICENSE file. | 5 * found in the LICENSE file. |
6 */ | 6 */ |
7 | 7 |
8 #ifndef SkBlitRow_opts_SSE4_DEFINED | 8 #ifndef SkBlitRow_opts_SSE4_DEFINED |
9 #define SkBlitRow_opts_SSE4_DEFINED | 9 #define SkBlitRow_opts_SSE4_DEFINED |
10 | 10 |
11 #include "SkBlitRow.h" | 11 #include "SkBlitRow.h" |
12 | 12 |
13 /* Check if we are able to build assembly code, GCC/AT&T syntax. | 13 /* Check if we are able to build assembly code, GCC/AT&T syntax: |
14 * Had problems with LLVM-GCC 4.2. | 14 * 1) Clang and GCC are generally OK. OS X's old LLVM-GCC 4.2 can't handle it; |
Nico
2014/07/02 19:05:46
(fwiw, we don't use OS X's llvm-gcc in chrome. May
| |
15 * MemorySanitizer cannot handle assembly code. | 15 * 2) Clang for Windows doesn't support AT&T syntax; |
Reid Kleckner
2014/07/02 19:04:48
This comment isn't true, Clang can probably assemb
Nico
2014/07/02 19:05:46
I think it does – the problem on the bug is just t
| |
16 * 3) MemorySanitizer cannot instrument assembly at all. | |
16 */ | 17 */ |
17 #if (defined(__clang__) || (defined(__GNUC__) && !defined(SK_BUILD_FOR_MAC))) \ | 18 #if /* 1)*/ (defined(__clang__) || (defined(__GNUC__) && !defined(SK_BUILD_FOR_M AC))) \ |
18 && !defined(MEMORY_SANITIZER) | 19 /* 2)*/ && !defined(SK_BUILD_FOR_WIN) \ |
20 /* 3)*/ && !defined(MEMORY_SANITIZER) | |
19 extern "C" void S32A_Opaque_BlitRow32_SSE4_asm(SkPMColor* SK_RESTRICT dst, | 21 extern "C" void S32A_Opaque_BlitRow32_SSE4_asm(SkPMColor* SK_RESTRICT dst, |
20 const SkPMColor* SK_RESTRICT src, | 22 const SkPMColor* SK_RESTRICT src, |
21 int count, U8CPU alpha); | 23 int count, U8CPU alpha); |
22 | 24 |
23 #define SK_ATT_ASM_SUPPORTED | 25 #define SK_ATT_ASM_SUPPORTED |
24 #endif | 26 #endif |
25 | 27 |
26 #endif | 28 #endif |
27 | 29 |
OLD | NEW |