Mercurial > hg > graal-jvmci-8
comparison src/cpu/sparc/vm/c1_LIRAssembler_sparc.cpp @ 6853:d804e148cff8
Merge
author | kvn |
---|---|
date | Fri, 12 Oct 2012 09:22:52 -0700 |
parents | d8ce2825b193 94e9408dbf50 |
children | 46f6f063b272 |
comparison
equal
deleted
inserted
replaced
6842:b9a9ed0f8eeb | 6853:d804e148cff8 |
---|---|
103 if (UseCompressedOops) { | 103 if (UseCompressedOops) { |
104 if (dst->is_address() && !dst->is_stack() && (dst->type() == T_OBJECT || dst->type() == T_ARRAY)) return false; | 104 if (dst->is_address() && !dst->is_stack() && (dst->type() == T_OBJECT || dst->type() == T_ARRAY)) return false; |
105 if (src->is_address() && !src->is_stack() && (src->type() == T_OBJECT || src->type() == T_ARRAY)) return false; | 105 if (src->is_address() && !src->is_stack() && (src->type() == T_OBJECT || src->type() == T_ARRAY)) return false; |
106 } | 106 } |
107 | 107 |
108 if (UseCompressedKlassPointers) { | |
109 if (src->is_address() && !src->is_stack() && src->type() == T_ADDRESS && | |
110 src->as_address_ptr()->disp() == oopDesc::klass_offset_in_bytes()) return false; | |
111 } | |
112 | |
108 if (dst->is_register()) { | 113 if (dst->is_register()) { |
109 if (src->is_address() && Assembler::is_simm13(src->as_address_ptr()->disp())) { | 114 if (src->is_address() && Assembler::is_simm13(src->as_address_ptr()->disp())) { |
110 return !PatchALot; | 115 return !PatchALot; |
111 } else if (src->is_single_stack()) { | 116 } else if (src->is_single_stack()) { |
112 return true; | 117 return true; |
967 __ ld(base, offset + hi_word_offset_in_bytes, to_reg->as_register_hi()); | 972 __ ld(base, offset + hi_word_offset_in_bytes, to_reg->as_register_hi()); |
968 } | 973 } |
969 #endif | 974 #endif |
970 } | 975 } |
971 break; | 976 break; |
972 case T_METADATA: | 977 case T_METADATA: __ ld_ptr(base, offset, to_reg->as_register()); break; |
973 case T_ADDRESS: __ ld_ptr(base, offset, to_reg->as_register()); break; | 978 case T_ADDRESS: |
979 #ifdef _LP64 | |
980 if (offset == oopDesc::klass_offset_in_bytes() && UseCompressedKlassPointers) { | |
981 __ lduw(base, offset, to_reg->as_register()); | |
982 __ decode_klass_not_null(to_reg->as_register()); | |
983 } else | |
984 #endif | |
985 { | |
986 __ ld_ptr(base, offset, to_reg->as_register()); | |
987 } | |
988 break; | |
974 case T_ARRAY : // fall through | 989 case T_ARRAY : // fall through |
975 case T_OBJECT: | 990 case T_OBJECT: |
976 { | 991 { |
977 if (UseCompressedOops && !wide) { | 992 if (UseCompressedOops && !wide) { |
978 __ lduw(base, offset, to_reg->as_register()); | 993 __ lduw(base, offset, to_reg->as_register()); |
2342 Label known_ok, halt; | 2357 Label known_ok, halt; |
2343 metadata2reg(op->expected_type()->constant_encoding(), tmp); | 2358 metadata2reg(op->expected_type()->constant_encoding(), tmp); |
2344 if (UseCompressedKlassPointers) { | 2359 if (UseCompressedKlassPointers) { |
2345 // tmp holds the default type. It currently comes uncompressed after the | 2360 // tmp holds the default type. It currently comes uncompressed after the |
2346 // load of a constant, so encode it. | 2361 // load of a constant, so encode it. |
2347 __ encode_heap_oop(tmp); | 2362 __ encode_klass_not_null(tmp); |
2348 // load the raw value of the dst klass, since we will be comparing | 2363 // load the raw value of the dst klass, since we will be comparing |
2349 // uncompressed values directly. | 2364 // uncompressed values directly. |
2350 __ lduw(dst, oopDesc::klass_offset_in_bytes(), tmp2); | 2365 __ lduw(dst, oopDesc::klass_offset_in_bytes(), tmp2); |
2351 if (basic_type != T_OBJECT) { | 2366 if (basic_type != T_OBJECT) { |
2352 __ cmp(tmp, tmp2); | 2367 __ cmp(tmp, tmp2); |