Fixes for linux64

This commit is contained in:
castano 2007-06-17 06:47:36 +00:00
parent acbebcc444
commit c4c6b95a50
2 changed files with 55 additions and 55 deletions

View File

@ -176,7 +176,7 @@ namespace
return (void *)ucp->uc_mcontext.gregs[REG_RIP]; return (void *)ucp->uc_mcontext.gregs[REG_RIP];
# elif NV_CPU_X86 # elif NV_CPU_X86
ucontext_t * ucp = (ucontext_t *)secret; ucontext_t * ucp = (ucontext_t *)secret;
return (void *)ucp->uc_mcontext.gregs[REG_EIP]; // 14 return (void *)ucp->uc_mcontext.gregs[14/*REG_EIP*/];
# elif NV_CPU_PPC # elif NV_CPU_PPC
ucontext_t * ucp = (ucontext_t *)secret; ucontext_t * ucp = (ucontext_t *)secret;
return (void *) ucp->uc_mcontext.regs->nip; return (void *) ucp->uc_mcontext.regs->nip;
@ -233,7 +233,7 @@ namespace
if (pnt != NULL) { if (pnt != NULL) {
// Overwrite sigaction with caller's address. // Overwrite sigaction with caller's address.
ucontext_t * uc = (ucontext_t *)secret; ucontext_t * uc = (ucontext_t *)secret;
trace[1] = (void *) uc->uc_mcontext.gregs[REG_EIP]; trace[1] = pnt;
} }
nvPrintStackTrace(trace, size, 1); nvPrintStackTrace(trace, size, 1);

View File

@ -67,7 +67,7 @@
#endif // NV_NO_ASSERT #endif // NV_NO_ASSERT
// Use nvAssume for very simple expresions only: piAssume(0), piAssume(value == true), etc. // Use nvAssume for very simple expresions only: nvAssume(0), nvAssume(value == true), etc.
#if defined(_DEBUG) #if defined(_DEBUG)
# if NV_CC_MSVC # if NV_CC_MSVC
# define nvAssume(exp) __assume(exp) # define nvAssume(exp) __assume(exp)