Mercurial > hg > graal-compiler
comparison src/cpu/sparc/vm/vtableStubs_sparc.cpp @ 642:660978a2a31a
6791178: Specialize for zero as the compressed oop vm heap base
Summary: Use zero based compressed oops if java heap is below 32gb and unscaled compressed oops if java heap is below 4gb.
Reviewed-by: never, twisti, jcoomes, coleenp
author | kvn |
---|---|
date | Thu, 12 Mar 2009 10:37:46 -0700 |
parents | 9adddb8c0fc8 |
children | 1d037ecd7960 |
comparison
equal
deleted
inserted
replaced
641:6af0a709d52b | 642:660978a2a31a |
---|---|
219 else { | 219 else { |
220 const int slop = 2*BytesPerInstWord; // sethi;add (needed for long offsets) | 220 const int slop = 2*BytesPerInstWord; // sethi;add (needed for long offsets) |
221 if (is_vtable_stub) { | 221 if (is_vtable_stub) { |
222 // ld;ld;ld,jmp,nop | 222 // ld;ld;ld,jmp,nop |
223 const int basic = 5*BytesPerInstWord + | 223 const int basic = 5*BytesPerInstWord + |
224 // shift;add for load_klass | 224 // shift;add for load_klass (only shift with zero heap based) |
225 (UseCompressedOops ? 2*BytesPerInstWord : 0); | 225 (UseCompressedOops ? |
226 ((Universe::narrow_oop_base() == NULL) ? BytesPerInstWord : 2*BytesPerInstWord) : 0); | |
226 return basic + slop; | 227 return basic + slop; |
227 } else { | 228 } else { |
228 const int basic = (28 LP64_ONLY(+ 6)) * BytesPerInstWord + | 229 const int basic = (28 LP64_ONLY(+ 6)) * BytesPerInstWord + |
229 // shift;add for load_klass | 230 // shift;add for load_klass (only shift with zero heap based) |
230 (UseCompressedOops ? 2*BytesPerInstWord : 0); | 231 (UseCompressedOops ? |
232 ((Universe::narrow_oop_base() == NULL) ? BytesPerInstWord : 2*BytesPerInstWord) : 0); | |
231 return (basic + slop); | 233 return (basic + slop); |
232 } | 234 } |
233 } | 235 } |
234 } | 236 } |
235 | 237 |