comparison src/share/vm/oops/constantPool.hpp @ 13102:f9f4503a4ab5

Merge
author Christos Kotselidis <christos.kotselidis@oracle.com>
date Thu, 21 Nov 2013 15:04:54 +0100
parents 096c224171c4
children
comparison
equal deleted inserted replaced
13101:790ebab62d23 13102:f9f4503a4ab5
109 int _resolved_reference_length; 109 int _resolved_reference_length;
110 // keeps version number for redefined classes (used in backtrace) 110 // keeps version number for redefined classes (used in backtrace)
111 int _version; 111 int _version;
112 } _saved; 112 } _saved;
113 113
114 Monitor* _lock;
114 115
115 void set_tags(Array<u1>* tags) { _tags = tags; } 116 void set_tags(Array<u1>* tags) { _tags = tags; }
116 void tag_at_put(int which, jbyte t) { tags()->at_put(which, t); } 117 void tag_at_put(int which, jbyte t) { tags()->at_put(which, t); }
117 void release_tag_at_put(int which, jbyte t) { tags()->release_at_put(which, t); } 118 void release_tag_at_put(int which, jbyte t) { tags()->release_at_put(which, t); }
118 119
843 _saved._version = version >= 0 ? (version + 1) : version; // keep overflow 844 _saved._version = version >= 0 ? (version + 1) : version; // keep overflow
844 } 845 }
845 846
846 void set_resolved_reference_length(int length) { _saved._resolved_reference_length = length; } 847 void set_resolved_reference_length(int length) { _saved._resolved_reference_length = length; }
847 int resolved_reference_length() const { return _saved._resolved_reference_length; } 848 int resolved_reference_length() const { return _saved._resolved_reference_length; }
848 849 void set_lock(Monitor* lock) { _lock = lock; }
849 // lock() may return null -- constant pool updates may happen before this lock is 850 Monitor* lock() { return _lock; }
850 // initialized, because the _pool_holder has not been fully initialized and
851 // has not been registered into the system dictionary. In this case, no other
852 // thread can be modifying this constantpool, so no synchronization is
853 // necessary.
854 //
855 // Use cplock() like this:
856 // oop cplock = cp->lock();
857 // ObjectLocker ol(cplock , THREAD, cplock != NULL);
858 oop lock();
859 851
860 // Decrease ref counts of symbols that are in the constant pool 852 // Decrease ref counts of symbols that are in the constant pool
861 // when the holder class is unloaded 853 // when the holder class is unloaded
862 void unreference_symbols(); 854 void unreference_symbols();
863 855