Index: src/platform-linux.cc |
diff --git a/src/platform-linux.cc b/src/platform-linux.cc |
index bfcd8fba7237e1c28306e59664ce0c4d433932c4..93f23f33cc7d47d6e9b50bf6ae4ea9f45624c9c6 100644 |
--- a/src/platform-linux.cc |
+++ b/src/platform-linux.cc |
@@ -707,23 +707,23 @@ static void ProfilerSignalHandler(int signal, siginfo_t* info, void* context) { |
ucontext_t* ucontext = reinterpret_cast<ucontext_t*>(context); |
mcontext_t& mcontext = ucontext->uc_mcontext; |
#if V8_HOST_ARCH_IA32 |
- sample.pc = mcontext.gregs[REG_EIP]; |
- sample.sp = mcontext.gregs[REG_ESP]; |
- sample.fp = mcontext.gregs[REG_EBP]; |
+ sample.pc = reinterpret_cast<Address>(mcontext.gregs[REG_EIP]); |
+ sample.sp = reinterpret_cast<Address>(mcontext.gregs[REG_ESP]); |
+ sample.fp = reinterpret_cast<Address>(mcontext.gregs[REG_EBP]); |
#elif V8_HOST_ARCH_X64 |
- sample.pc = mcontext.gregs[REG_RIP]; |
- sample.sp = mcontext.gregs[REG_RSP]; |
- sample.fp = mcontext.gregs[REG_RBP]; |
+ sample.pc = reinterpret_cast<Address>(mcontext.gregs[REG_RIP]); |
+ sample.sp = reinterpret_cast<Address>(mcontext.gregs[REG_RSP]); |
+ sample.fp = reinterpret_cast<Address>(mcontext.gregs[REG_RBP]); |
#elif V8_HOST_ARCH_ARM |
// An undefined macro evaluates to 0, so this applies to Android's Bionic also. |
#if (__GLIBC__ < 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ <= 3)) |
- sample.pc = mcontext.gregs[R15]; |
- sample.sp = mcontext.gregs[R13]; |
- sample.fp = mcontext.gregs[R11]; |
+ sample.pc = reinterpret_cast<Address>(mcontext.gregs[R15]); |
+ sample.sp = reinterpret_cast<Address>(mcontext.gregs[R13]); |
+ sample.fp = reinterpret_cast<Address>(mcontext.gregs[R11]); |
#else |
- sample.pc = mcontext.arm_pc; |
- sample.sp = mcontext.arm_sp; |
- sample.fp = mcontext.arm_fp; |
+ sample.pc = reinterpret_cast<Address>(mcontext.arm_pc); |
+ sample.sp = reinterpret_cast<Address>(mcontext.arm_sp); |
+ sample.fp = reinterpret_cast<Address>(mcontext.arm_fp); |
#endif |
#endif |
if (IsVmThread()) |