diff --git a/src/SOS/lldbplugin/services.cpp b/src/SOS/lldbplugin/services.cpp index f056814beb..291f0f677a 100644 --- a/src/SOS/lldbplugin/services.cpp +++ b/src/SOS/lldbplugin/services.cpp @@ -231,6 +231,8 @@ LLDBServices::VirtualUnwind( DWORD spToFind = dtcontext->Sp; #elif DBG_TARGET_ARM64 DWORD64 spToFind = dtcontext->Sp; +#elif DBG_TARGET_RISCV64 + DWORD64 spToFind = dtcontext->Sp; #else #error "spToFind undefined for this platform" #endif @@ -454,6 +456,8 @@ LLDBServices::GetExecutingProcessorType( *type = IMAGE_FILE_MACHINE_ARM64; #elif DBG_TARGET_X86 *type = IMAGE_FILE_MACHINE_I386; +#elif DBG_TARGET_RISCV64 + *type = IMAGE_FILE_MACHINE_RISCV64; #else #error "Unsupported target" #endif diff --git a/src/shared/inc/regdisp.h b/src/shared/inc/regdisp.h index 02e67dbdd4..406e3365f3 100644 --- a/src/shared/inc/regdisp.h +++ b/src/shared/inc/regdisp.h @@ -226,12 +226,12 @@ struct REGDISPLAY : public REGDISPLAY_BASE { inline TADDR GetRegdisplayFP(REGDISPLAY *display) { LIMITED_METHOD_CONTRACT; - return NULL; + return (TADDR)NULL; } inline TADDR GetRegdisplayFPAddress(REGDISPLAY *display) { LIMITED_METHOD_CONTRACT; - return NULL; + return (TADDR)NULL; } // This function tells us if the given stack pointer is in one of the frames of the functions called by the given frame @@ -248,14 +248,14 @@ inline TADDR GetRegdisplayStackMark(REGDISPLAY *display) _ASSERTE(GetRegdisplaySP(display) == GetSP(display->pCurrentContext)); return GetRegdisplaySP(display); -#elif defined(TARGET_ARM64) +#elif defined(TARGET_ARM64) || defined(TARGET_RISCV64) _ASSERTE(display->IsCallerContextValid); return GetSP(display->pCallerContext); #else // TARGET_AMD64 PORTABILITY_ASSERT("GetRegdisplayStackMark NYI for this platform (Regdisp.h)"); - return NULL; + return (TADDR)NULL; #endif // TARGET_AMD64 }