| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (c) 2011 The Native Client Authors. All rights reserved. | 2 * Copyright (c) 2011 The Native Client Authors. All rights reserved. |
| 3 * Use of this source code is governed by a BSD-style license that can be | 3 * Use of this source code is governed by a BSD-style license that can be |
| 4 * found in the LICENSE file. | 4 * found in the LICENSE file. |
| 5 */ | 5 */ |
| 6 | 6 |
| 7 #ifndef NATIVE_CLIENT_SRC_INCLUDE_NACL_COMPILER_ANNOTATIONS_H_ | 7 #ifndef NATIVE_CLIENT_SRC_INCLUDE_NACL_COMPILER_ANNOTATIONS_H_ |
| 8 #define NATIVE_CLIENT_SRC_INCLUDE_NACL_COMPILER_ANNOTATIONS_H_ | 8 #define NATIVE_CLIENT_SRC_INCLUDE_NACL_COMPILER_ANNOTATIONS_H_ |
| 9 | 9 |
| 10 #include "native_client/src/include/nacl_defines.h" |
| 11 |
| 10 /* MSVC supports "inline" only in C++ */ | 12 /* MSVC supports "inline" only in C++ */ |
| 11 #if NACL_WINDOWS | 13 #if NACL_WINDOWS |
| 12 # define INLINE __forceinline | 14 # define INLINE __forceinline |
| 13 #else | 15 #else |
| 14 # define INLINE __inline__ | 16 # define INLINE __inline__ |
| 15 #endif | 17 #endif |
| 16 | 18 |
| 17 #if NACL_WINDOWS | 19 #if NACL_WINDOWS |
| 18 # define DLLEXPORT __declspec(dllexport) | 20 # define DLLEXPORT __declspec(dllexport) |
| 19 #elif NACL_LINUX || NACL_OSX | 21 #elif NACL_LINUX || NACL_OSX |
| (...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 94 */ | 96 */ |
| 95 #if defined(__GNUC__) | 97 #if defined(__GNUC__) |
| 96 # define NACL_LIKELY(x) (__builtin_expect((x) != 0, 1)) | 98 # define NACL_LIKELY(x) (__builtin_expect((x) != 0, 1)) |
| 97 # define NACL_UNLIKELY(x) (__builtin_expect((x) != 0, 0)) | 99 # define NACL_UNLIKELY(x) (__builtin_expect((x) != 0, 0)) |
| 98 #else | 100 #else |
| 99 # define NACL_LIKELY(x) (x) | 101 # define NACL_LIKELY(x) (x) |
| 100 # define NACL_UNLIKELY(x) (x) | 102 # define NACL_UNLIKELY(x) (x) |
| 101 #endif | 103 #endif |
| 102 | 104 |
| 103 #endif | 105 #endif |
| OLD | NEW |