equal
deleted
inserted
replaced
436 inline static bool checkByteBuffer(address pc, address* stub) { |
436 inline static bool checkByteBuffer(address pc, address* stub) { |
437 // BugId 4454115: A read from a MappedByteBuffer can fault |
437 // BugId 4454115: A read from a MappedByteBuffer can fault |
438 // here if the underlying file has been truncated. |
438 // here if the underlying file has been truncated. |
439 // Do not crash the VM in such a case. |
439 // Do not crash the VM in such a case. |
440 CodeBlob* cb = CodeCache::find_blob_unsafe(pc); |
440 CodeBlob* cb = CodeCache::find_blob_unsafe(pc); |
441 nmethod* nm = cb->is_nmethod() ? (nmethod*)cb : NULL; |
441 CompiledMethod* nm = cb->as_compiled_method_or_null(); |
442 if (nm != NULL && nm->has_unsafe_access()) { |
442 if (nm != NULL && nm->has_unsafe_access()) { |
443 *stub = StubRoutines::handler_for_unsafe_access(); |
443 *stub = StubRoutines::handler_for_unsafe_access(); |
444 return true; |
444 return true; |
445 } |
445 } |
446 return false; |
446 return false; |