Mercurial > hg > truffle
comparison src/share/vm/services/memTracker.cpp @ 10355:fb14e9ed1594
8011064: Some tests have failed with SIGSEGV on arm-hflt on build b82
Summary: NMT_detail is only supported when frame pointers are not omitted (-fno-omit-frame-pointer).
Reviewed-by: dholmes, cjplummer
author | jprovino |
---|---|
date | Tue, 28 May 2013 11:32:46 -0400 |
parents | fbca7eaeac2e |
children | 1f4355cee9a2 16b10327b00d |
comparison
equal
deleted
inserted
replaced
10339:194b27b865bc | 10355:fb14e9ed1594 |
---|---|
32 #include "runtime/vm_operations.hpp" | 32 #include "runtime/vm_operations.hpp" |
33 #include "services/memPtr.hpp" | 33 #include "services/memPtr.hpp" |
34 #include "services/memReporter.hpp" | 34 #include "services/memReporter.hpp" |
35 #include "services/memTracker.hpp" | 35 #include "services/memTracker.hpp" |
36 #include "utilities/decoder.hpp" | 36 #include "utilities/decoder.hpp" |
37 #include "utilities/defaultStream.hpp" | |
37 #include "utilities/globalDefinitions.hpp" | 38 #include "utilities/globalDefinitions.hpp" |
38 | 39 |
39 bool NMT_track_callsite = false; | 40 bool NMT_track_callsite = false; |
40 | 41 |
41 // walk all 'known' threads at NMT sync point, and collect their recorders | 42 // walk all 'known' threads at NMT sync point, and collect their recorders |
75 void MemTracker::init_tracking_options(const char* option_line) { | 76 void MemTracker::init_tracking_options(const char* option_line) { |
76 _tracking_level = NMT_off; | 77 _tracking_level = NMT_off; |
77 if (strcmp(option_line, "=summary") == 0) { | 78 if (strcmp(option_line, "=summary") == 0) { |
78 _tracking_level = NMT_summary; | 79 _tracking_level = NMT_summary; |
79 } else if (strcmp(option_line, "=detail") == 0) { | 80 } else if (strcmp(option_line, "=detail") == 0) { |
80 _tracking_level = NMT_detail; | 81 // detail relies on a stack-walking ability that may not |
82 // be available depending on platform and/or compiler flags | |
83 if (PLATFORM_NMT_DETAIL_SUPPORTED) { | |
84 _tracking_level = NMT_detail; | |
85 } else { | |
86 jio_fprintf(defaultStream::error_stream(), | |
87 "NMT detail is not supported on this platform. Using NMT summary instead."); | |
88 _tracking_level = NMT_summary; | |
89 } | |
81 } else if (strcmp(option_line, "=off") != 0) { | 90 } else if (strcmp(option_line, "=off") != 0) { |
82 vm_exit_during_initialization("Syntax error, expecting -XX:NativeMemoryTracking=[off|summary|detail]", NULL); | 91 vm_exit_during_initialization("Syntax error, expecting -XX:NativeMemoryTracking=[off|summary|detail]", NULL); |
83 } | 92 } |
84 } | 93 } |
85 | 94 |