Mercurial > hg > truffle
diff src/share/vm/runtime/stackValue.cpp @ 858:5314d85ffd54
6826736: CMS: core dump with -XX:+UseCompressedOops
Summary: Fix deoptimization code and OopMapSet::all_do() to check for oop = narrow_oop_base.
Reviewed-by: jcoomes, phh, ysr, never
author | kvn |
---|---|
date | Wed, 22 Jul 2009 15:48:51 -0700 |
parents | b109e761e927 |
children | 18f526145aea |
line wrap: on
line diff
--- a/src/share/vm/runtime/stackValue.cpp Tue Jul 21 21:33:44 2009 -0700 +++ b/src/share/vm/runtime/stackValue.cpp Wed Jul 22 15:48:51 2009 -0700 @@ -104,7 +104,17 @@ } #endif case Location::oop: { - Handle h(*(oop *)value_addr); // Wrap a handle around the oop + oop val = *(oop *)value_addr; +#ifdef _LP64 + if (Universe::is_narrow_oop_base(val)) { + // Compiled code may produce decoded oop = narrow_oop_base + // when a narrow oop implicit null check is used. + // The narrow_oop_base could be NULL or be the address + // of the page below heap. Use NULL value for both cases. + val = (oop)NULL; + } +#endif + Handle h(val); // Wrap a handle around the oop return new StackValue(h); } case Location::addr: {