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 PLATFORM_GLOBALS_H_ | 5 #ifndef PLATFORM_GLOBALS_H_ |
6 #define PLATFORM_GLOBALS_H_ | 6 #define 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 280 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
291 // exit(), which end the program. We use it to avoid compiler warnings in | 291 // exit(), which end the program. We use it to avoid compiler warnings in |
292 // callers of DART_NORETURN functions. | 292 // callers of DART_NORETURN functions. |
293 #ifdef _MSC_VER | 293 #ifdef _MSC_VER |
294 #define DART_NORETURN __declspec(noreturn) | 294 #define DART_NORETURN __declspec(noreturn) |
295 #elif __GNUC__ | 295 #elif __GNUC__ |
296 #define DART_NORETURN __attribute__((noreturn)) | 296 #define DART_NORETURN __attribute__((noreturn)) |
297 #else | 297 #else |
298 #error Automatic compiler detection failed. | 298 #error Automatic compiler detection failed. |
299 #endif | 299 #endif |
300 | 300 |
| 301 #ifdef _MSC_VER |
| 302 #define DART_PRETTY_FUNCTION __FUNCSIG__ |
| 303 #elif __GNUC__ |
| 304 #define DART_PRETTY_FUNCTION __PRETTY_FUNCTION__ |
| 305 #else |
| 306 #error Automatic compiler detection failed. |
| 307 #endif |
| 308 |
301 #if !defined(TARGET_ARCH_MIPS) | 309 #if !defined(TARGET_ARCH_MIPS) |
302 #if !defined(TARGET_ARCH_ARM) | 310 #if !defined(TARGET_ARCH_ARM) |
303 #if !defined(TARGET_ARCH_X64) | 311 #if !defined(TARGET_ARCH_X64) |
304 #if !defined(TARGET_ARCH_IA32) | 312 #if !defined(TARGET_ARCH_IA32) |
305 #if !defined(TARGET_ARCH_ARM64) | 313 #if !defined(TARGET_ARCH_ARM64) |
306 #if !defined(TARGET_ARCH_DBC) | 314 #if !defined(TARGET_ARCH_DBC) |
307 // No target architecture specified pick the one matching the host architecture. | 315 // No target architecture specified pick the one matching the host architecture. |
308 #if defined(HOST_ARCH_MIPS) | 316 #if defined(HOST_ARCH_MIPS) |
309 #define TARGET_ARCH_MIPS 1 | 317 #define TARGET_ARCH_MIPS 1 |
310 #elif defined(HOST_ARCH_ARM) | 318 #elif defined(HOST_ARCH_ARM) |
(...skipping 388 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
699 // tag in the ICData and check it when recreating the flow graph in | 707 // tag in the ICData and check it when recreating the flow graph in |
700 // optimizing compiler. Enable it for other modes (product, release) if needed | 708 // optimizing compiler. Enable it for other modes (product, release) if needed |
701 // for debugging. | 709 // for debugging. |
702 #if defined(DEBUG) | 710 #if defined(DEBUG) |
703 #define TAG_IC_DATA | 711 #define TAG_IC_DATA |
704 #endif | 712 #endif |
705 | 713 |
706 } // namespace dart | 714 } // namespace dart |
707 | 715 |
708 #endif // PLATFORM_GLOBALS_H_ | 716 #endif // PLATFORM_GLOBALS_H_ |
OLD | NEW |