14 *
15 * You should have received a copy of the GNU General Public License version
16 * 2 along with this work; if not, write to the Free Software Foundation,
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18 *
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
20 * or visit www.oracle.com if you need additional information or have any
21 * questions.
22 *
23 */
24
25 #include "precompiled.hpp"
26 #include "memory/allocation.inline.hpp"
27 #include "opto/ad.hpp"
28 #include "opto/block.hpp"
29 #include "opto/c2compiler.hpp"
30 #include "opto/callnode.hpp"
31 #include "opto/cfgnode.hpp"
32 #include "opto/machnode.hpp"
33 #include "opto/runtime.hpp"
34
35 // Optimization - Graph Style
36
37 // Check whether val is not-null-decoded compressed oop,
38 // i.e. will grab into the base of the heap if it represents NULL.
39 static bool accesses_heap_base_zone(Node *val) {
40 if (Universe::narrow_oop_base() > 0) { // Implies UseCompressedOops.
41 if (val && val->is_Mach()) {
42 if (val->as_Mach()->ideal_Opcode() == Op_DecodeN) {
43 // This assumes all Decodes with TypePtr::NotNull are matched to nodes that
44 // decode NULL to point to the heap base (Decode_NN).
45 if (val->bottom_type()->is_oopptr()->ptr() == TypePtr::NotNull) {
46 return true;
47 }
48 }
49 // Must recognize load operation with Decode matched in memory operand.
50 // We should not reach here exept for PPC/AIX, as os::zero_page_read_protected()
51 // returns true everywhere else. On PPC, no such memory operands
52 // exist, therefore we did not yet implement a check for such operands.
53 NOT_AIX(Unimplemented());
|
14 *
15 * You should have received a copy of the GNU General Public License version
16 * 2 along with this work; if not, write to the Free Software Foundation,
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18 *
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
20 * or visit www.oracle.com if you need additional information or have any
21 * questions.
22 *
23 */
24
25 #include "precompiled.hpp"
26 #include "memory/allocation.inline.hpp"
27 #include "opto/ad.hpp"
28 #include "opto/block.hpp"
29 #include "opto/c2compiler.hpp"
30 #include "opto/callnode.hpp"
31 #include "opto/cfgnode.hpp"
32 #include "opto/machnode.hpp"
33 #include "opto/runtime.hpp"
34 #include "runtime/sharedRuntime.hpp"
35
36 // Optimization - Graph Style
37
38 // Check whether val is not-null-decoded compressed oop,
39 // i.e. will grab into the base of the heap if it represents NULL.
40 static bool accesses_heap_base_zone(Node *val) {
41 if (Universe::narrow_oop_base() > 0) { // Implies UseCompressedOops.
42 if (val && val->is_Mach()) {
43 if (val->as_Mach()->ideal_Opcode() == Op_DecodeN) {
44 // This assumes all Decodes with TypePtr::NotNull are matched to nodes that
45 // decode NULL to point to the heap base (Decode_NN).
46 if (val->bottom_type()->is_oopptr()->ptr() == TypePtr::NotNull) {
47 return true;
48 }
49 }
50 // Must recognize load operation with Decode matched in memory operand.
51 // We should not reach here exept for PPC/AIX, as os::zero_page_read_protected()
52 // returns true everywhere else. On PPC, no such memory operands
53 // exist, therefore we did not yet implement a check for such operands.
54 NOT_AIX(Unimplemented());
|