Mercurial > hg > truffle
diff src/share/vm/graal/graalCompilerToVM.cpp @ 6379:ad97777056ec
Checks on vtableEntryOffset to avoid calling to the VM if the holder is not initialized
author | Gilles Duboscq <duboscq@ssw.jku.at> |
---|---|
date | Wed, 12 Sep 2012 13:07:35 +0200 |
parents | 908e40db1d94 |
children | a718f153b9f2 |
line wrap: on
line diff
--- a/src/share/vm/graal/graalCompilerToVM.cpp Wed Sep 12 11:29:34 2012 +0200 +++ b/src/share/vm/graal/graalCompilerToVM.cpp Wed Sep 12 13:07:35 2012 +0200 @@ -939,6 +939,7 @@ methodOop method = getMethodFromHotSpotMethod(hotspot_method); assert(!instanceKlass::cast(method->method_holder())->is_interface(), "vtableEntryOffset cannot be called for interface methods"); + assert(instanceKlass::cast(method->method_holder())->is_linked(), "vtableEntryOffset cannot be called is holder is not linked"); // get entry offset in words int vtable_entry_offset = instanceKlass::vtable_start_offset() + method->vtable_index() * vtableEntry::size();