changeset 27283:e42b45e12cef

Merge
author mgronlun
date Tue, 12 Jan 2016 16:01:54 +0100
parents 4f4969a0bb13 2abdc525b6b4
children d5912f3407fe 42a4b9a221cc fd5d53ecf040
files
diffstat 2 files changed, 3 insertions(+), 10 deletions(-) [+]
line wrap: on
line diff
--- a/src/share/vm/trace/traceEventClasses.xsl	Tue Jan 12 11:11:21 2016 +0100
+++ b/src/share/vm/trace/traceEventClasses.xsl	Tue Jan 12 16:01:54 2016 +0100
@@ -36,7 +36,6 @@
 // Some parts of traceEvent.hpp are used outside of
 // INCLUDE_TRACE
 
-#include "memory/resourceArea.hpp"
 #include "tracefiles/traceTypes.hpp"
 #include "trace/traceEvent.hpp"
 #include "utilities/macros.hpp"
@@ -136,7 +135,6 @@
 </xsl:text>
   <xsl:value-of select="concat('  Event', @id, '(EventStartTime timing=TIMED) : TraceEvent&lt;Event', @id, '&gt;(timing) {}', $newline)"/>
   void writeEvent(void) {
-    ResourceMark rm;
     if (UseLockedTracing) {
       ttyLocker lock;
       writeEventContent();
--- a/src/share/vm/trace/traceStream.hpp	Tue Jan 12 11:11:21 2016 +0100
+++ b/src/share/vm/trace/traceStream.hpp	Tue Jan 12 16:01:54 2016 +0100
@@ -27,6 +27,7 @@
 
 #include "utilities/macros.hpp"
 #if INCLUDE_TRACE
+#include "memory/resourceArea.hpp"
 #include "oops/klass.hpp"
 #include "oops/method.hpp"
 #include "oops/symbol.hpp"
@@ -79,11 +80,8 @@
     _st.print("%s = %f", label, val);
   }
 
-  // Caller is machine generated code located in traceEventClasses.hpp
-  // Event<TraceId>::writeEvent() (pseudocode) contains the
-  // necessary ResourceMark for the resource allocations below.
-  // See traceEventClasses.xsl for details.
   void print_val(const char* label, const Klass* const val) {
+    ResourceMark rm;
     const char* description = "NULL";
     if (val != NULL) {
       Symbol* name = val->name();
@@ -94,11 +92,8 @@
     _st.print("%s = %s", label, description);
   }
 
-  // Caller is machine generated code located in traceEventClasses.hpp
-  // Event<TraceId>::writeEvent() (pseudocode) contains the
-  // necessary ResourceMark for the resource allocations below.
-  // See traceEventClasses.xsl for details.
   void print_val(const char* label, const Method* const val) {
+    ResourceMark rm;
     const char* description = "NULL";
     if (val != NULL) {
       description = val->name_and_sig_as_C_string();