8075967: Zero interpreter asserts for SafeFetch<32,N> calls in ObjectMonitor

Implement SafeFetchX unsafely and make CanUseSafeFetchX false for Zero

Reviewed-by: sgehwolf, dholmes
This commit is contained in:
Coleen Phillimore 2015-03-25 22:27:51 -04:00
parent 3e6cf09c39
commit b115f80cb5
4 changed files with 29 additions and 7 deletions

View file

@ -450,7 +450,15 @@ inline intptr_t SafeFetchN(intptr_t* adr, intptr_t errValue) {
// returns true if SafeFetch32 and SafeFetchN can be used safely (stubroutines are already generated)
inline bool CanUseSafeFetch32() { return StubRoutines::SafeFetch32_stub() ? true : false; }
inline bool CanUseSafeFetchN() { return StubRoutines::SafeFetchN_stub() ? true : false; }
inline bool CanUseSafeFetch32() {
// All platforms have the stub but ZERO isn't safe.
assert(StubRoutines::SafeFetch32_stub() != NULL, "should have generated stub");
return NOT_ZERO(true) ZERO_ONLY(false);
}
inline bool CanUseSafeFetchN() {
// All platforms have the stub but ZERO isn't safe.
assert(StubRoutines::SafeFetchN_stub() != NULL, "should have generated stub");
return NOT_ZERO(true) ZERO_ONLY(false);
}
#endif // SHARE_VM_RUNTIME_STUBROUTINES_HPP