On Wed, 10 Feb 2021 01:53:38 GMT, Yasumasa Suenaga <ysuen...@openjdk.org> wrote:
>> Lin Zang has updated the pull request incrementally with one additional >> commit since the last revision: >> >> refine code in test. > > src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/utilities/HeapHprofBinWriter.java > line 1504: > >> 1502: segmentBuffer[segmentWritten++] = (byte)(v >>> 8); >> 1503: segmentBuffer[segmentWritten++] = (byte)(v >>> 0); >> 1504: } > > I'm not familiar to hprof format, but I guess we need to write them with big > endian. > Can we use `ByteBuffer::putInt` and `ByteBuffer::order` at here? I guess it > makes ease to maintenance. Nice Catch! I will make the change, Thanks @YaSuenag ! ------------- PR: https://git.openjdk.java.net/jdk/pull/1712