comparison src/share/vm/ci/ciObjectFactory.cpp @ 2491:0654ee04b214

Merge with OpenJDK.
author Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
date Fri, 22 Apr 2011 15:30:53 +0200
parents d25d4ca69222 c7f3d0b4570f
children 0e8a2a629afb
comparison
equal deleted inserted replaced
2490:29246b1d2d3c 2491:0654ee04b214
1 /* 1 /*
2 * Copyright (c) 1999, 2010, Oracle and/or its affiliates. All rights reserved. 2 * Copyright (c) 1999, 2011, Oracle and/or its affiliates. All rights reserved.
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 * 4 *
5 * This code is free software; you can redistribute it and/or modify it 5 * This code is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU General Public License version 2 only, as 6 * under the terms of the GNU General Public License version 2 only, as
7 * published by the Free Software Foundation. 7 * published by the Free Software Foundation.
348 } else if (o->is_methodData()) { 348 } else if (o->is_methodData()) {
349 methodDataHandle h_md(THREAD, (methodDataOop)o); 349 methodDataHandle h_md(THREAD, (methodDataOop)o);
350 return new (arena()) ciMethodData(h_md); 350 return new (arena()) ciMethodData(h_md);
351 } else if (o->is_instance()) { 351 } else if (o->is_instance()) {
352 instanceHandle h_i(THREAD, (instanceOop)o); 352 instanceHandle h_i(THREAD, (instanceOop)o);
353 if (java_dyn_CallSite::is_instance(o)) 353 if (java_lang_invoke_CallSite::is_instance(o))
354 return new (arena()) ciCallSite(h_i); 354 return new (arena()) ciCallSite(h_i);
355 else if (java_dyn_MethodHandle::is_instance(o)) 355 else if (java_lang_invoke_MethodHandle::is_instance(o))
356 return new (arena()) ciMethodHandle(h_i); 356 return new (arena()) ciMethodHandle(h_i);
357 else 357 else
358 return new (arena()) ciInstance(h_i); 358 return new (arena()) ciInstance(h_i);
359 } else if (o->is_objArray()) { 359 } else if (o->is_objArray()) {
360 objArrayHandle h_oa(THREAD, (objArrayOop)o); 360 objArrayHandle h_oa(THREAD, (objArrayOop)o);
669 // Thus, there might be a matching perm object in the table. 669 // Thus, there might be a matching perm object in the table.
670 // If there is, this probe must find it. 670 // If there is, this probe must find it.
671 if (key->is_perm() && _non_perm_count == 0) { 671 if (key->is_perm() && _non_perm_count == 0) {
672 return emptyBucket; 672 return emptyBucket;
673 } else if (key->is_instance()) { 673 } else if (key->is_instance()) {
674 if (key->klass() == SystemDictionary::Class_klass()) { 674 if (key->klass() == SystemDictionary::Class_klass() && JavaObjectsInPerm) {
675 // class mirror instances are always perm 675 // class mirror instances are always perm
676 return emptyBucket; 676 return emptyBucket;
677 } 677 }
678 // fall through to probe 678 // fall through to probe
679 } else if (key->is_array()) { 679 } else if (key->is_array()) {