8011064: Some tests have failed with SIGSEGV on arm-hflt on build b82

Tue, 28 May 2013 11:32:46 -0400

author
jprovino
date
Tue, 28 May 2013 11:32:46 -0400
changeset 5188
fb14e9ed1594
parent 5172
194b27b865bc
child 5189
9e954e8d9139

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

src/share/vm/services/memTracker.cpp file | annotate | diff | comparison | revisions
src/share/vm/utilities/globalDefinitions.hpp file | annotate | diff | comparison | revisions
     1.1 --- a/src/share/vm/services/memTracker.cpp	Fri May 24 09:35:10 2013 -0700
     1.2 +++ b/src/share/vm/services/memTracker.cpp	Tue May 28 11:32:46 2013 -0400
     1.3 @@ -34,6 +34,7 @@
     1.4  #include "services/memReporter.hpp"
     1.5  #include "services/memTracker.hpp"
     1.6  #include "utilities/decoder.hpp"
     1.7 +#include "utilities/defaultStream.hpp"
     1.8  #include "utilities/globalDefinitions.hpp"
     1.9  
    1.10  bool NMT_track_callsite = false;
    1.11 @@ -77,7 +78,15 @@
    1.12    if (strcmp(option_line, "=summary") == 0) {
    1.13      _tracking_level = NMT_summary;
    1.14    } else if (strcmp(option_line, "=detail") == 0) {
    1.15 -    _tracking_level = NMT_detail;
    1.16 +    // detail relies on a stack-walking ability that may not
    1.17 +    // be available depending on platform and/or compiler flags
    1.18 +    if (PLATFORM_NMT_DETAIL_SUPPORTED) {
    1.19 +      _tracking_level = NMT_detail;
    1.20 +    } else {
    1.21 +      jio_fprintf(defaultStream::error_stream(),
    1.22 +        "NMT detail is not supported on this platform.  Using NMT summary instead.");
    1.23 +      _tracking_level = NMT_summary;
    1.24 +    }
    1.25    } else if (strcmp(option_line, "=off") != 0) {
    1.26      vm_exit_during_initialization("Syntax error, expecting -XX:NativeMemoryTracking=[off|summary|detail]", NULL);
    1.27    }
     2.1 --- a/src/share/vm/utilities/globalDefinitions.hpp	Fri May 24 09:35:10 2013 -0700
     2.2 +++ b/src/share/vm/utilities/globalDefinitions.hpp	Tue May 28 11:32:46 2013 -0400
     2.3 @@ -380,6 +380,14 @@
     2.4  # include "globalDefinitions_ppc.hpp"
     2.5  #endif
     2.6  
     2.7 +/*
     2.8 + * If a platform does not support NMT_detail
     2.9 + * the platform specific globalDefinitions (above)
    2.10 + * can set PLATFORM_NMT_DETAIL_SUPPORTED to false
    2.11 + */
    2.12 +#ifndef PLATFORM_NMT_DETAIL_SUPPORTED
    2.13 +#define PLATFORM_NMT_DETAIL_SUPPORTED true
    2.14 +#endif
    2.15  
    2.16  // The byte alignment to be used by Arena::Amalloc.  See bugid 4169348.
    2.17  // Note: this value must be a power of 2

mercurial