8237637: Remove dubious type conversions from oop

Reviewed-by: kbarrett, dholmes, mdoerr
This commit is contained in:
Stefan Karlsson 2020-01-24 09:27:07 +01:00
parent b223907794
commit 46423b0f70
83 changed files with 163 additions and 215 deletions

View file

@ -44,7 +44,7 @@ inline void ParallelScavengeHeap::invoke_scavenge() {
inline bool ParallelScavengeHeap::is_in_young(oop p) {
// Assumes the the old gen address range is lower than that of the young gen.
bool result = ((HeapWord*)p) >= young_gen()->reserved().start();
bool result = cast_from_oop<HeapWord*>(p) >= young_gen()->reserved().start();
assert(result == young_gen()->is_in_reserved(p),
"incorrect test - result=%d, p=" PTR_FORMAT, result, p2i((void*)p));
return result;