31#pragma warning(disable : 271 310)
50static int __kmp_console_exists =
FALSE;
56 if (__kmp_console_exists) {
60 __kmp_console_exists =
FALSE;
66static void __kmp_redirect_output(
void) {
69 if (!__kmp_console_exists) {
81 ho = GetStdHandle(STD_OUTPUT_HANDLE);
82 if (ho == INVALID_HANDLE_VALUE || ho == NULL) {
84 DWORD
err = GetLastError();
93 he = GetStdHandle(STD_ERROR_HANDLE);
94 if (he == INVALID_HANDLE_VALUE || he == NULL) {
96 DWORD
err = GetLastError();
105 __kmp_console_exists =
TRUE;
111#define __kmp_stderr (stderr)
112#define __kmp_stdout (stdout)
117 if (!__kmp_console_exists) {
118 __kmp_redirect_output();
146 "OMP warning: Debugging buffer "
147 "overflow; increase "
148 "KMP_DEBUG_BUF_CHARS to %d\n",
150 WriteFile(stream, __kmp_console_buf.
str, __kmp_console_buf.
used, &
count,
155 "OMP warning: Debugging buffer overflow; "
156 "increase KMP_DEBUG_BUF_CHARS to %d\n",
173 WriteFile(stream, __kmp_console_buf.
str, __kmp_console_buf.
used, &
count,
178 fprintf(stream,
"pid=%d: ", (
kmp_int32)getpid());
180 vfprintf(stream, format, ap);
188 va_start(ap, format);
199 va_start(ap, format);
208 va_start(ap, format);
void const char const char int ITT_FORMAT __itt_group_sync x void const char ITT_FORMAT __itt_group_sync s void ITT_FORMAT __itt_group_sync p void ITT_FORMAT p void ITT_FORMAT p no args __itt_suppress_mode_t unsigned int void size_t ITT_FORMAT d void ITT_FORMAT p void ITT_FORMAT p __itt_model_site __itt_model_site_instance ITT_FORMAT p __itt_model_task __itt_model_task_instance ITT_FORMAT p void ITT_FORMAT p void ITT_FORMAT p void size_t ITT_FORMAT d void ITT_FORMAT p const wchar_t ITT_FORMAT s const char ITT_FORMAT s const char ITT_FORMAT s const char ITT_FORMAT s no args void ITT_FORMAT p size_t count
int __kmp_debug_buf_lines
int __kmp_debug_buf_chars
char * __kmp_debug_buffer
int __kmp_debug_buf_warn_chars
std::atomic< int > __kmp_debug_count
kmp_bootstrap_lock_t __kmp_console_lock
kmp_bootstrap_lock_t __kmp_stdio_lock
void __kmp_fprintf(enum kmp_io stream, char const *format,...)
void __kmp_vprintf(enum kmp_io out_stream, char const *format, va_list ap)
void __kmp_printf(char const *format,...)
void __kmp_printf_no_lock(char const *format,...)
void __kmp_close_console(void)
static void __kmp_release_bootstrap_lock(kmp_bootstrap_lock_t *lck)
static int __kmp_acquire_bootstrap_lock(kmp_bootstrap_lock_t *lck)
#define KMP_BOOTSTRAP_LOCK_INITIALIZER(lock)
void __kmp_str_buf_clear(kmp_str_buf_t *buffer)
int __kmp_str_buf_vprint(kmp_str_buf_t *buffer, char const *format, va_list args)
void __kmp_str_buf_free(kmp_str_buf_t *buffer)
int __kmp_str_buf_print(kmp_str_buf_t *buffer, char const *format,...)
#define __kmp_str_buf_init(b)