# HG changeset patch # User Yasumasa Suenaga # Date 1523192377 -32400 # Node ID ef2b74a8df08da218859801fe7f66c36aff1d38b # Parent c4954777fe6fbc0e9764d736da7cd2c11c61e6f5 Bug 3570: Build warning on Arm box Reviewed-by: ykubota https://github.com/HeapStats/heapstats/pull/139 diff -r c4954777fe6f -r ef2b74a8df08 ChangeLog --- a/ChangeLog Tue Apr 03 19:33:38 2018 +0900 +++ b/ChangeLog Sun Apr 08 21:59:37 2018 +0900 @@ -1,3 +1,7 @@ +2018-04-08 Yasumasa Suenaga + + * Bug 3570: Build warning on Arm box + 2018-04-03 Yasumasa Suenaga * Bug 3528: Support Serial GC on JDK 10 diff -r c4954777fe6f -r ef2b74a8df08 agent/src/arch/arm/heapstats_md_arm.cpp --- a/agent/src/arch/arm/heapstats_md_arm.cpp Tue Apr 03 19:33:38 2018 +0900 +++ b/agent/src/arch/arm/heapstats_md_arm.cpp Sun Apr 08 21:59:37 2018 +0900 @@ -2,7 +2,7 @@ * \file heapstats_md_arm.cpp * \brief Proxy library for HeapStats backend. * This file implements ARM specific code for loading backend library. - * Copyright (C) 2015 Yasumasa Suenaga + * Copyright (C) 2015-2018 Yasumasa Suenaga * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License @@ -48,10 +48,10 @@ */ static int findHeapStatsCallback(struct dl_phdr_info *info, size_t size, void *data) { - ptrdiff_t this_func_addr = (ptrdiff_t)&findHeapStatsCallback; + uintptr_t this_func_addr = (uintptr_t)&findHeapStatsCallback; for (int idx = 0; idx < info->dlpi_phnum; idx++) { - ptrdiff_t base_addr = info->dlpi_addr + info->dlpi_phdr[idx].p_vaddr; + uintptr_t base_addr = info->dlpi_addr + info->dlpi_phdr[idx].p_vaddr; if ((this_func_addr >= base_addr) && (this_func_addr <= base_addr + info->dlpi_phdr[idx].p_memsz)) {