mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-26 22:34:27 +02:00
8189748: More precise closures for WeakProcessor::weak_oops_do calls
Reviewed-by: pliden, sjohanss
This commit is contained in:
parent
817d6bc039
commit
d129d1cdf2
14 changed files with 90 additions and 75 deletions
|
@ -30,6 +30,7 @@
|
|||
#include "compiler/oopMap.hpp"
|
||||
#include "gc/shared/collectedHeap.hpp"
|
||||
#include "memory/allocation.inline.hpp"
|
||||
#include "memory/iterator.hpp"
|
||||
#include "memory/resourceArea.hpp"
|
||||
#include "runtime/frame.inline.hpp"
|
||||
#include "runtime/signature.hpp"
|
||||
|
@ -263,13 +264,6 @@ OopMap* OopMapSet::find_map_at_offset(int pc_offset) const {
|
|||
return m;
|
||||
}
|
||||
|
||||
class DoNothingClosure: public OopClosure {
|
||||
public:
|
||||
void do_oop(oop* p) {}
|
||||
void do_oop(narrowOop* p) {}
|
||||
};
|
||||
static DoNothingClosure do_nothing;
|
||||
|
||||
static void add_derived_oop(oop* base, oop* derived) {
|
||||
#if !defined(TIERED) && !defined(INCLUDE_JVMCI)
|
||||
COMPILER1_PRESENT(ShouldNotReachHere();)
|
||||
|
@ -310,7 +304,7 @@ static void trace_codeblob_maps(const frame *fr, const RegisterMap *reg_map) {
|
|||
|
||||
void OopMapSet::oops_do(const frame *fr, const RegisterMap* reg_map, OopClosure* f) {
|
||||
// add derived oops to a table
|
||||
all_do(fr, reg_map, f, add_derived_oop, &do_nothing);
|
||||
all_do(fr, reg_map, f, add_derived_oop, &do_nothing_cl);
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue