Code review request: 2 Native Memory Tracking bugs

Karen Kinnear karen.kinnear at
Wed Aug 1 13:01:09 PDT 2012


Thank you also for putting in the additional debug information to try to get more information on the duplicate pointer assertion which is so hard to catch.

Couple of questions:

1. MemTrackWorker.cpp
line 134 transites -> transits

When you call shutdown, do you also want to break out of the loop? (which would change the assertion at the end)
Or is there any potential hard in continuing to loop?

2. MemTracker.hpp
Might it make sense to put the shutdown check in ceate_memory_record so you don't need to check all callers?
But wait - it already is in create_memory_record ... so did you need to add it in those cases?


On Aug 1, 2012, at 1:39 PM, Zhengyu Gu wrote:

> These are two simple fixes for NMT.
> CR: 7185614 NMT ON: "check by caller" assertion failed on nsk ThreadMXBean test ( 
>   The assertion was incorrect, since there can be a race condition between caller's check and assertion. The assertion is now removed, shutdown in progress is checked instead. 
> CR: 7187429 NMT ON: Merge failure should cause NMT to shutdown (
>   Out-of-memory is the only cause to merge failure, to be consistent, NMT should shutdown itself.
> Webrev: 
> Thanks,
> -Zhengyu

-------------- next part --------------
An HTML attachment was scrubbed...

More information about the hotspot-runtime-dev mailing list