OLD | NEW |
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
4 | 4 |
5 #ifndef RUNTIME_PLATFORM_GLOBALS_H_ | 5 #ifndef RUNTIME_PLATFORM_GLOBALS_H_ |
6 #define RUNTIME_PLATFORM_GLOBALS_H_ | 6 #define RUNTIME_PLATFORM_GLOBALS_H_ |
7 | 7 |
8 // __STDC_FORMAT_MACROS has to be defined before including <inttypes.h> to | 8 // __STDC_FORMAT_MACROS has to be defined before including <inttypes.h> to |
9 // enable platform independent printf format specifiers. | 9 // enable platform independent printf format specifiers. |
10 #ifndef __STDC_FORMAT_MACROS | 10 #ifndef __STDC_FORMAT_MACROS |
(...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
121 #endif | 121 #endif |
122 | 122 |
123 | 123 |
124 // Setup product, release or debug build related macros. | 124 // Setup product, release or debug build related macros. |
125 #if defined(PRODUCT) && defined(DEBUG) | 125 #if defined(PRODUCT) && defined(DEBUG) |
126 #error Both PRODUCT and DEBUG defined. | 126 #error Both PRODUCT and DEBUG defined. |
127 #endif // defined(PRODUCT) && defined(DEBUG) | 127 #endif // defined(PRODUCT) && defined(DEBUG) |
128 | 128 |
129 #if defined(PRODUCT) | 129 #if defined(PRODUCT) |
130 #define NOT_IN_PRODUCT(code) | 130 #define NOT_IN_PRODUCT(code) |
131 #define DEBUG_ONLY(code) | |
132 #else // defined(PRODUCT) | 131 #else // defined(PRODUCT) |
133 #define NOT_IN_PRODUCT(code) code | 132 #define NOT_IN_PRODUCT(code) code |
| 133 #endif // defined(PRODUCT) |
| 134 |
134 #if defined(DEBUG) | 135 #if defined(DEBUG) |
135 #define DEBUG_ONLY(code) code | 136 #define DEBUG_ONLY(code) code |
136 #else // defined(DEBUG) | 137 #else // defined(DEBUG) |
137 #define DEBUG_ONLY(code) | 138 #define DEBUG_ONLY(code) |
138 #endif // defined(DEBUG) | 139 #endif // defined(DEBUG) |
139 #endif // defined(PRODUCT) | |
140 | 140 |
141 #if defined(DART_PRECOMPILED_RUNTIME) && defined(DART_PRECOMPILER) | 141 #if defined(DART_PRECOMPILED_RUNTIME) && defined(DART_PRECOMPILER) |
142 #error DART_PRECOMPILED_RUNTIME and DART_PRECOMPILER are mutually exclusive | 142 #error DART_PRECOMPILED_RUNTIME and DART_PRECOMPILER are mutually exclusive |
143 #endif // defined(DART_PRECOMPILED_RUNTIME) && defined(DART_PRECOMPILER) | 143 #endif // defined(DART_PRECOMPILED_RUNTIME) && defined(DART_PRECOMPILER) |
144 | 144 |
145 #if defined(DART_PRECOMPILED_RUNTIME) | 145 #if defined(DART_PRECOMPILED_RUNTIME) |
146 #define NOT_IN_PRECOMPILED(code) | 146 #define NOT_IN_PRECOMPILED(code) |
147 #else | 147 #else |
148 #define NOT_IN_PRECOMPILED(code) code | 148 #define NOT_IN_PRECOMPILED(code) code |
149 #endif // defined(DART_PRECOMPILED_RUNTIME) | 149 #endif // defined(DART_PRECOMPILED_RUNTIME) |
(...skipping 552 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
702 // tag in the ICData and check it when recreating the flow graph in | 702 // tag in the ICData and check it when recreating the flow graph in |
703 // optimizing compiler. Enable it for other modes (product, release) if needed | 703 // optimizing compiler. Enable it for other modes (product, release) if needed |
704 // for debugging. | 704 // for debugging. |
705 #if defined(DEBUG) | 705 #if defined(DEBUG) |
706 #define TAG_IC_DATA | 706 #define TAG_IC_DATA |
707 #endif | 707 #endif |
708 | 708 |
709 } // namespace dart | 709 } // namespace dart |
710 | 710 |
711 #endif // RUNTIME_PLATFORM_GLOBALS_H_ | 711 #endif // RUNTIME_PLATFORM_GLOBALS_H_ |
OLD | NEW |