mirror of
https://github.com/openjdk/jdk.git
synced 2025-09-20 19:14:38 +02:00
Merge
This commit is contained in:
commit
d6a9b93b5a
133 changed files with 1889 additions and 1307 deletions
|
@ -512,7 +512,7 @@ class RelocIterator : public StackObj {
|
|||
address _limit; // stop producing relocations after this _addr
|
||||
relocInfo* _current; // the current relocation information
|
||||
relocInfo* _end; // end marker; we're done iterating when _current == _end
|
||||
CodeBlob* _code; // compiled method containing _addr
|
||||
nmethod* _code; // compiled method containing _addr
|
||||
address _addr; // instruction to which the relocation applies
|
||||
short _databuf; // spare buffer for compressed data
|
||||
short* _data; // pointer to the relocation's data
|
||||
|
@ -549,7 +549,7 @@ class RelocIterator : public StackObj {
|
|||
|
||||
address compute_section_start(int n) const; // out-of-line helper
|
||||
|
||||
void initialize(CodeBlob* nm, address begin, address limit);
|
||||
void initialize(nmethod* nm, address begin, address limit);
|
||||
|
||||
friend class PatchingRelocIterator;
|
||||
// make an uninitialized one, for PatchingRelocIterator:
|
||||
|
@ -557,7 +557,7 @@ class RelocIterator : public StackObj {
|
|||
|
||||
public:
|
||||
// constructor
|
||||
RelocIterator(CodeBlob* cb, address begin = NULL, address limit = NULL);
|
||||
RelocIterator(nmethod* nm, address begin = NULL, address limit = NULL);
|
||||
RelocIterator(CodeSection* cb, address begin = NULL, address limit = NULL);
|
||||
|
||||
// get next reloc info, return !eos
|
||||
|
@ -592,7 +592,7 @@ class RelocIterator : public StackObj {
|
|||
relocType type() const { return current()->type(); }
|
||||
int format() const { return (relocInfo::have_format) ? current()->format() : 0; }
|
||||
address addr() const { return _addr; }
|
||||
CodeBlob* code() const { return _code; }
|
||||
nmethod* code() const { return _code; }
|
||||
short* data() const { return _data; }
|
||||
int datalen() const { return _datalen; }
|
||||
bool has_current() const { return _datalen >= 0; }
|
||||
|
@ -790,9 +790,9 @@ class Relocation VALUE_OBJ_CLASS_SPEC {
|
|||
|
||||
public:
|
||||
// accessors which only make sense for a bound Relocation
|
||||
address addr() const { return binding()->addr(); }
|
||||
CodeBlob* code() const { return binding()->code(); }
|
||||
bool addr_in_const() const { return binding()->addr_in_const(); }
|
||||
address addr() const { return binding()->addr(); }
|
||||
nmethod* code() const { return binding()->code(); }
|
||||
bool addr_in_const() const { return binding()->addr_in_const(); }
|
||||
protected:
|
||||
short* data() const { return binding()->data(); }
|
||||
int datalen() const { return binding()->datalen(); }
|
||||
|
@ -982,12 +982,12 @@ class virtual_call_Relocation : public CallRelocation {
|
|||
|
||||
// Figure out where an ic_call is hiding, given a set-oop or call.
|
||||
// Either ic_call or first_oop must be non-null; the other is deduced.
|
||||
// Code if non-NULL must be the CodeBlob, else it is deduced.
|
||||
// Code if non-NULL must be the nmethod, else it is deduced.
|
||||
// The address of the patchable oop is also deduced.
|
||||
// The returned iterator will enumerate over the oops and the ic_call,
|
||||
// as well as any other relocations that happen to be in that span of code.
|
||||
// Recognize relevant set_oops with: oop_reloc()->oop_addr() == oop_addr.
|
||||
static RelocIterator parse_ic(CodeBlob* &code, address &ic_call, address &first_oop, oop* &oop_addr, bool *is_optimized);
|
||||
static RelocIterator parse_ic(nmethod* &nm, address &ic_call, address &first_oop, oop* &oop_addr, bool *is_optimized);
|
||||
};
|
||||
|
||||
|
||||
|
@ -1304,8 +1304,8 @@ inline name##_Relocation* RelocIterator::name##_reloc() { \
|
|||
APPLY_TO_RELOCATIONS(EACH_CASE);
|
||||
#undef EACH_CASE
|
||||
|
||||
inline RelocIterator::RelocIterator(CodeBlob* cb, address begin, address limit) {
|
||||
initialize(cb, begin, limit);
|
||||
inline RelocIterator::RelocIterator(nmethod* nm, address begin, address limit) {
|
||||
initialize(nm, begin, limit);
|
||||
}
|
||||
|
||||
// if you are going to patch code, you should use this subclass of
|
||||
|
@ -1323,8 +1323,8 @@ class PatchingRelocIterator : public RelocIterator {
|
|||
void operator=(const RelocIterator&);
|
||||
|
||||
public:
|
||||
PatchingRelocIterator(CodeBlob* cb, address begin =NULL, address limit =NULL)
|
||||
: RelocIterator(cb, begin, limit) { prepass(); }
|
||||
PatchingRelocIterator(nmethod* nm, address begin = NULL, address limit = NULL)
|
||||
: RelocIterator(nm, begin, limit) { prepass(); }
|
||||
|
||||
~PatchingRelocIterator() { postpass(); }
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue