Index: compiler-rt/lib/sanitizer_common/sanitizer_common.h =================================================================== --- compiler-rt/lib/sanitizer_common/sanitizer_common.h +++ compiler-rt/lib/sanitizer_common/sanitizer_common.h @@ -674,7 +674,8 @@ kModuleArchARMV7, kModuleArchARMV7S, kModuleArchARMV7K, - kModuleArchARM64 + kModuleArchARM64, + kModuleArchRISCV }; // Opens the file 'file_name" and reads up to 'max_len' bytes. @@ -718,6 +719,8 @@ return "armv7k"; case kModuleArchARM64: return "arm64"; + case kModuleArchRISCV: + return "riscv"; } CHECK(0 && "Invalid module arch"); return ""; Index: compiler-rt/lib/sanitizer_common/sanitizer_symbolizer_libcdep.cpp =================================================================== --- compiler-rt/lib/sanitizer_common/sanitizer_symbolizer_libcdep.cpp +++ compiler-rt/lib/sanitizer_common/sanitizer_symbolizer_libcdep.cpp @@ -270,6 +270,8 @@ const char* const kSymbolizerArch = "--default-arch=s390x"; #elif defined(__s390__) const char* const kSymbolizerArch = "--default-arch=s390"; +#elif defined(__riscv__) + const char* const kSymbolizerArch = "--default-arch=riscv"; #else const char* const kSymbolizerArch = "--default-arch=unknown"; #endif