diff options
author | Youling Tang <tangyouling@loongson.cn> | 2023-07-18 09:40:20 +0800 |
---|---|---|
committer | zhanglimin <zhanglimin@loongson.cn> | 2023-07-18 09:40:25 +0800 |
commit | 9c2f792dceb626f57c577b02468562e1e84822f1 (patch) | |
tree | 5b3168d0bb25581e3e05e5c3db7e6e4a35a82dbe /compiler-rt | |
parent | e0ac46e69d7adbe327148550ffafe746cbc0ec78 (diff) | |
download | llvm-9c2f792dceb626f57c577b02468562e1e84822f1.zip llvm-9c2f792dceb626f57c577b02468562e1e84822f1.tar.gz llvm-9c2f792dceb626f57c577b02468562e1e84822f1.tar.bz2 |
[fuzzer] Enable loongarch64
Enable fuzzer on loongarch64.
Reviewed By: SixWeining, xen0n, MaskRay
Differential Revision: https://reviews.llvm.org/D140601
Diffstat (limited to 'compiler-rt')
-rw-r--r-- | compiler-rt/cmake/Modules/AllSupportedArchDefs.cmake | 2 | ||||
-rw-r--r-- | compiler-rt/lib/fuzzer/FuzzerTracePC.cpp | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/compiler-rt/cmake/Modules/AllSupportedArchDefs.cmake b/compiler-rt/cmake/Modules/AllSupportedArchDefs.cmake index 70847d2..d14745e 100644 --- a/compiler-rt/cmake/Modules/AllSupportedArchDefs.cmake +++ b/compiler-rt/cmake/Modules/AllSupportedArchDefs.cmake @@ -40,7 +40,7 @@ endif() if(OS_NAME MATCHES "Linux") set(ALL_FUZZER_SUPPORTED_ARCH ${X86} ${X86_64} ${ARM32} ${ARM64} ${S390X} - ${RISCV64}) + ${RISCV64} ${LOONGARCH64}) elseif (OS_NAME MATCHES "Windows") set(ALL_FUZZER_SUPPORTED_ARCH ${X86} ${X86_64}) elseif(OS_NAME MATCHES "Android") diff --git a/compiler-rt/lib/fuzzer/FuzzerTracePC.cpp b/compiler-rt/lib/fuzzer/FuzzerTracePC.cpp index f12f7aa..7f4e8ef 100644 --- a/compiler-rt/lib/fuzzer/FuzzerTracePC.cpp +++ b/compiler-rt/lib/fuzzer/FuzzerTracePC.cpp @@ -149,8 +149,8 @@ inline ALWAYS_INLINE uintptr_t GetPreviousInstructionPc(uintptr_t PC) { ALWAYS_INLINE uintptr_t TracePC::GetNextInstructionPc(uintptr_t PC) { #if defined(__mips__) return PC + 8; -#elif defined(__powerpc__) || defined(__sparc__) || defined(__arm__) || \ - defined(__aarch64__) +#elif defined(__powerpc__) || defined(__sparc__) || defined(__arm__) || \ + defined(__aarch64__) || defined(__loongarch__) return PC + 4; #else return PC + 1; |