comparison src/share/vm/oops/constantPool.hpp @ 7643:3ac7d10a6572

Merge with hsx25/hotspot.
author Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
date Thu, 31 Jan 2013 15:42:25 +0100
parents e522a00b91aa b5f6465019f6
children 5fc51c1ecdeb
comparison
equal deleted inserted replaced
7573:17b6a63fe7c2 7643:3ac7d10a6572
1 /* 1 /*
2 * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. 2 * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 * 4 *
5 * This code is free software; you can redistribute it and/or modify it 5 * This code is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU General Public License version 2 only, as 6 * under the terms of the GNU General Public License version 2 only, as
7 * published by the Free Software Foundation. 7 * published by the Free Software Foundation.
101 bool _on_stack; // Redefined method still executing refers to this constant pool. 101 bool _on_stack; // Redefined method still executing refers to this constant pool.
102 102
103 union { 103 union {
104 // set for CDS to restore resolved references 104 // set for CDS to restore resolved references
105 int _resolved_reference_length; 105 int _resolved_reference_length;
106 // only set to non-zero if constant pool is merged by RedefineClasses 106 // keeps version number for redefined classes (used in backtrace)
107 int _orig_length; 107 int _version;
108 } _saved; 108 } _saved;
109 109
110 Monitor* _lock; 110 Monitor* _lock;
111 111
112 void set_tags(Array<u1>* tags) { _tags = tags; } 112 void set_tags(Array<u1>* tags) { _tags = tags; }
784 copy_cp_to_impl(h_this, start_i, end_i, to_cp, to_i, THREAD); 784 copy_cp_to_impl(h_this, start_i, end_i, to_cp, to_i, THREAD);
785 } 785 }
786 static void copy_cp_to_impl(constantPoolHandle from_cp, int start_i, int end_i, constantPoolHandle to_cp, int to_i, TRAPS); 786 static void copy_cp_to_impl(constantPoolHandle from_cp, int start_i, int end_i, constantPoolHandle to_cp, int to_i, TRAPS);
787 static void copy_entry_to(constantPoolHandle from_cp, int from_i, constantPoolHandle to_cp, int to_i, TRAPS); 787 static void copy_entry_to(constantPoolHandle from_cp, int from_i, constantPoolHandle to_cp, int to_i, TRAPS);
788 int find_matching_entry(int pattern_i, constantPoolHandle search_cp, TRAPS); 788 int find_matching_entry(int pattern_i, constantPoolHandle search_cp, TRAPS);
789 int orig_length() const { return _saved._orig_length; } 789 int version() const { return _saved._version; }
790 void set_orig_length(int orig_length) { _saved._orig_length = orig_length; } 790 void set_version(int version) { _saved._version = version; }
791 void increment_and_save_version(int version) {
792 _saved._version = version >= 0 ? (version + 1) : version; // keep overflow
793 }
791 794
792 void set_resolved_reference_length(int length) { _saved._resolved_reference_length = length; } 795 void set_resolved_reference_length(int length) { _saved._resolved_reference_length = length; }
793 int resolved_reference_length() const { return _saved._resolved_reference_length; } 796 int resolved_reference_length() const { return _saved._resolved_reference_length; }
794 void set_lock(Monitor* lock) { _lock = lock; } 797 void set_lock(Monitor* lock) { _lock = lock; }
795 Monitor* lock() { return _lock; } 798 Monitor* lock() { return _lock; }