mirror of
https://github.com/abseil/abseil-cpp.git
synced 2026-06-04 20:14:23 +08:00
committed by
GitHub
parent
7055876380
commit
3fcd00d7dd
@@ -77,7 +77,8 @@ inline void* DirectMmap(void* start, size_t length, int prot, int flags, int fd,
|
||||
(defined(__mips__) && _MIPS_SIM == _MIPS_SIM_ABI32) || \
|
||||
(defined(__PPC__) && !defined(__PPC64__)) || \
|
||||
(defined(__riscv) && __riscv_xlen == 32) || \
|
||||
(defined(__s390__) && !defined(__s390x__))
|
||||
(defined(__s390__) && !defined(__s390x__)) || \
|
||||
(defined(__sparc__) && !defined(__arch64__))
|
||||
// On these architectures, implement mmap with mmap2.
|
||||
static int pagesize = 0;
|
||||
if (pagesize == 0) {
|
||||
|
||||
@@ -63,6 +63,10 @@ void* GetProgramCounter(void* vuc) {
|
||||
return reinterpret_cast<void*>(context->uc_mcontext.psw.addr & 0x7fffffff);
|
||||
#elif defined(__s390__) && defined(__s390x__)
|
||||
return reinterpret_cast<void*>(context->uc_mcontext.psw.addr);
|
||||
#elif defined(__sparc__) && !defined(__arch64__)
|
||||
return reinterpret_cast<void*>(context->uc_mcontext.gregs[19]);
|
||||
#elif defined(__sparc__) && defined(__arch64__)
|
||||
return reinterpret_cast<void*>(context->uc_mcontext.mc_gregs[19]);
|
||||
#elif defined(__x86_64__)
|
||||
if (16 < ABSL_ARRAYSIZE(context->uc_mcontext.gregs))
|
||||
return reinterpret_cast<void*>(context->uc_mcontext.gregs[16]);
|
||||
|
||||
Reference in New Issue
Block a user