< prev index next >
src/share/vm/asm/assembler.cpp
Print this page
rev 10763 : [backport] Fix build failures when Shenandoah is disabled, after #include reshuffles
rev 10764 : [backport] Rename BrooksPointer to ShenandoahBrooksPointer
@@ -24,11 +24,11 @@
#include "precompiled.hpp"
#include "asm/macroAssembler.hpp"
#include "asm/macroAssembler.inline.hpp"
#include "asm/codeBuffer.hpp"
-#include "gc_implementation/shenandoah/brooksPointer.hpp"
+#include "gc_implementation/shenandoah/shenandoahBrooksPointer.hpp"
#include "runtime/atomic.hpp"
#include "runtime/atomic.inline.hpp"
#include "runtime/icache.hpp"
#include "runtime/os.hpp"
@@ -314,21 +314,23 @@
assert (Universe::heap() != NULL, "java heap should be initialized");
// The first page after heap_base is unmapped and
// the 'offset' is equal to [heap_base + offset] for
// narrow oop implicit null checks.
uintptr_t base = (uintptr_t)Universe::narrow_oop_base();
- int adj = MIN2(0, UseShenandoahGC ? BrooksPointer::byte_offset() : 0);
+ int adj = 0;
+ if (UseShenandoahGC) {
+ adj = ShenandoahBrooksPointer::byte_offset();
+ assert(adj < 0, "no need for positive adjustments");
+ }
if ((uintptr_t)((offset - adj) & address_bits) >= base) {
// Normalize offset for the next check.
offset = (intptr_t)(pointer_delta((void*)offset, (void*)base, 1));
}
}
#endif
- if (UseShenandoahGC) {
- if ((offset & address_bits) == (BrooksPointer::byte_offset() & address_bits)) {
+ if (UseShenandoahGC && ((offset & address_bits) == (ShenandoahBrooksPointer::byte_offset() & address_bits))) {
return false;
}
- }
return offset < 0 || os::vm_page_size() <= offset;
}
< prev index next >