Mercurial > hg > truffle
diff src/share/vm/opto/machnode.cpp @ 113:ba764ed4b6f2
6420645: Create a vm that uses compressed oops for up to 32gb heapsizes
Summary: Compressed oops in instances, arrays, and headers. Code contributors are coleenp, phh, never, swamyv
Reviewed-by: jmasa, kamg, acorn, tbell, kvn, rasbold
author | coleenp |
---|---|
date | Sun, 13 Apr 2008 17:43:42 -0400 |
parents | a61af66fc99e |
children | d1605aabd0a1 8d191a7697e2 |
line wrap: on
line diff
--- a/src/share/vm/opto/machnode.cpp Fri Apr 11 09:56:35 2008 -0400 +++ b/src/share/vm/opto/machnode.cpp Sun Apr 13 17:43:42 2008 -0400 @@ -263,6 +263,13 @@ // See if it adds up to a base + offset. if (index != NULL) { if (!index->is_Con()) { + const TypeNarrowOop* narrowoop = index->bottom_type()->isa_narrowoop(); + if (narrowoop != NULL) { + // Memory references through narrow oops have a + // funny base so grab the type from the index. + adr_type = narrowoop->make_oopptr(); + return NULL; + } disp = Type::OffsetBot; } else if (disp != Type::OffsetBot) { const TypeX* ti = index->bottom_type()->isa_intptr_t();