8169941: CodeBlob::is_frame_complete_at() does not honor CodeOffsets::frame_never_safe
authorthartmann
Mon, 21 Nov 2016 09:33:06 +0100
changeset 42581 2fdb039ea5b5
parent 42580 56304dee97f3
child 42582 8a46057442cd
8169941: CodeBlob::is_frame_complete_at() does not honor CodeOffsets::frame_never_safe Summary: CodeBlob::is_frame_complete_at() should always return false if _frame_complete_offset is set to CodeOffsets::frame_never_safe (-1). Reviewed-by: kvn, dlong
hotspot/src/share/vm/code/codeBlob.hpp
--- a/hotspot/src/share/vm/code/codeBlob.hpp	Mon Nov 21 08:27:10 2016 +0100
+++ b/hotspot/src/share/vm/code/codeBlob.hpp	Mon Nov 21 09:33:06 2016 +0100
@@ -159,7 +159,8 @@
   bool blob_contains(address addr) const         { return header_begin()       <= addr && addr < data_end();       }
   bool code_contains(address addr) const         { return code_begin()         <= addr && addr < code_end();       }
   bool contains(address addr) const              { return content_begin()      <= addr && addr < content_end();    }
-  bool is_frame_complete_at(address addr) const  { return code_contains(addr) && addr >= code_begin() + _frame_complete_offset; }
+  bool is_frame_complete_at(address addr) const  { return _frame_complete_offset != CodeOffsets::frame_never_safe &&
+                                                          code_contains(addr) && addr >= code_begin() + _frame_complete_offset; }
 
   // CodeCache support: really only used by the nmethods, but in order to get
   // asserts and certain bookkeeping to work in the CodeCache they are defined