Esempio n. 1
0
void    __cdecl     debugStop(const char *why, ...)
{
    va_list     args;

    va_start(args, why);

    printf("NOTIFICATION: ");
    if  (why)
        vprintf(why, args);
    else
        printf("debugStop(0)");

    printf("\n");

    va_end(args);

    BreakIfDebuggerPresent();
}
Esempio n. 2
0
void debugError(const char* msg, const char* file, unsigned line) 
{
    const char* tail = strrchr(file, '\\');
    if (tail) file = tail+1;

    LogEnv* env = LogEnv::cur();

    logf(LL_ERROR, "COMPILATION FAILED: file: %s:%d compiling method %s reason %s\n", file, line, env->compiler->info.compFullName, msg);

    static ConfigDWORD fJitRequired;
    // We now only assert when user explicitly set ComPlus_JitRequired=1
    // If ComPlus_JitRequired is 0 or is not set, we will not assert.
    if (fJitRequired.val(CLRConfig::INTERNAL_JITRequired) == 1 || getBreakOnBadCode())
    {
            // Don't assert if verification is done.
        if (!env->compiler->tiVerificationNeeded || getBreakOnBadCode())
            assertAbort(msg, "NO-FILE", 0);
    }

    BreakIfDebuggerPresent();
}