Mercurial > hg > graal-jvmci-8
comparison src/share/vm/ci/ciKlass.cpp @ 1604:b918d354830a
6960865: ldc of unloaded class throws an assert in ciTypeFlow
Summary: Support java_mirror for unloaded klasses, arrays as well as instances. Simplify ciTypeFlow by removing unused path.
Reviewed-by: kvn
author | jrose |
---|---|
date | Sat, 12 Jun 2010 22:53:43 -0700 |
parents | c18cbe5936b8 |
children | f95d63e2154a |
comparison
equal
deleted
inserted
replaced
1603:d93949c5bdcc | 1604:b918d354830a |
---|---|
190 klass_name, false); | 190 klass_name, false); |
191 } | 191 } |
192 | 192 |
193 // ------------------------------------------------------------------ | 193 // ------------------------------------------------------------------ |
194 // ciKlass::java_mirror | 194 // ciKlass::java_mirror |
195 // | |
196 // Get the instance of java.lang.Class corresponding to this klass. | |
197 // If it is an unloaded instance or array klass, return an unloaded | |
198 // mirror object of type Class. | |
195 ciInstance* ciKlass::java_mirror() { | 199 ciInstance* ciKlass::java_mirror() { |
196 GUARDED_VM_ENTRY( | 200 GUARDED_VM_ENTRY( |
201 if (!is_loaded()) | |
202 return ciEnv::current()->get_unloaded_klass_mirror(this); | |
197 oop java_mirror = get_Klass()->java_mirror(); | 203 oop java_mirror = get_Klass()->java_mirror(); |
198 return CURRENT_ENV->get_object(java_mirror)->as_instance(); | 204 return CURRENT_ENV->get_object(java_mirror)->as_instance(); |
199 ) | 205 ) |
200 } | 206 } |
201 | 207 |