8142333: Build failure in debugInfoRec.cpp with SS12u4
authornever
Mon, 30 Nov 2015 15:21:25 -0800
changeset 34501 d914dfe7abf5
parent 34500 3c82f7ac03e6
child 34502 1cfcb971cb17
8142333: Build failure in debugInfoRec.cpp with SS12u4 Reviewed-by: coleenp, dholmes, erikj, kvn
hotspot/src/share/vm/code/debugInfoRec.cpp
--- a/hotspot/src/share/vm/code/debugInfoRec.cpp	Mon Oct 05 23:53:59 2015 +0200
+++ b/hotspot/src/share/vm/code/debugInfoRec.cpp	Mon Nov 30 15:21:25 2015 -0800
@@ -33,7 +33,7 @@
 // We keep track of these chunks in order to detect
 // repetition and enable sharing.
 class DIR_Chunk {
-  friend class DebugInformationRecorder;
+private:
   int  _offset; // location in the stream of this scope
   int  _length; // number of bytes in the stream
   int  _hash;   // hash of stream bytes (for quicker reuse)
@@ -41,6 +41,9 @@
   DebugInformationRecorder* _DIR;
 #endif
 
+public:
+  int offset() { return _offset; }
+
   void* operator new(size_t ignore, DebugInformationRecorder* dir) throw() {
     assert(ignore == sizeof(DIR_Chunk), "");
     if (dir->_next_chunk >= dir->_next_chunk_limit) {
@@ -284,7 +287,7 @@
     NOT_PRODUCT(++dir_stats.chunks_shared);
     assert(ns+1 == _next_chunk, "");
     _next_chunk = ns;
-    return match->_offset;
+    return match->offset();
   } else {
     // Inserted this chunk, so nothing to do
     return serialized_null;
@@ -296,7 +299,7 @@
     NOT_PRODUCT(++dir_stats.chunks_reshared);
     assert(ns+1 == _next_chunk, "");
     _next_chunk = ns;
-    return ms->_offset;
+    return ms->offset();
   }
 
   // Look in recently encountered scopes next:
@@ -311,7 +314,7 @@
     _shared_chunks->append(ms);
     assert(ns+1 == _next_chunk, "");
     _next_chunk = ns;
-    return ms->_offset;
+    return ms->offset();
   }
 
   // No match.  Add this guy to the list, in hopes of future shares.