< prev index next >

src/share/vm/runtime/stubRoutines.hpp

Print this page
rev 7970 : 8074552:  SafeFetch32 and SafeFetchN do not work in error handling
Summary: handle SafeFetch faults in secondary signal handlers
Reviewed-by: dholmes
Contributed-by: Thomas Stuefe

@@ -456,6 +456,11 @@
 inline intptr_t SafeFetchN(intptr_t* adr, intptr_t errValue) {
   assert(StubRoutines::SafeFetchN_stub(), "stub not yet generated");
   return StubRoutines::SafeFetchN_stub()(adr, 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; }
+
 #endif // SHARE_VM_RUNTIME_STUBROUTINES_HPP
< prev index next >