< prev index next >

src/share/vm/c1/c1_Runtime1.cpp

Print this page

        

@@ -311,10 +311,11 @@
   FUNCTION_CASE(entry, SharedRuntime::lrem);
   FUNCTION_CASE(entry, SharedRuntime::lrem);
   FUNCTION_CASE(entry, SharedRuntime::dtrace_method_entry);
   FUNCTION_CASE(entry, SharedRuntime::dtrace_method_exit);
   FUNCTION_CASE(entry, is_instance_of);
+  FUNCTION_CASE(entry, is_primitive);
   FUNCTION_CASE(entry, trace_block_entry);
 #ifdef TRACE_HAVE_INTRINSICS
   FUNCTION_CASE(entry, TRACE_TIME_METHOD);
 #endif
   FUNCTION_CASE(entry, StubRoutines::updateBytesCRC32());

@@ -1486,10 +1487,17 @@
   assert(mirror != NULL, "should null-check on mirror before calling");
   Klass* k = java_lang_Class::as_Klass(mirror);
   return (k != NULL && obj != NULL && obj->is_a(k)) ? 1 : 0;
 JRT_END
 
+JRT_LEAF(int, Runtime1::is_primitive(oopDesc* mirror))
+  // had to return int instead of bool, otherwise there may be a mismatch
+  // between the C calling convention and the Java one.
+  assert(mirror != NULL, "should null-check on mirror before calling");
+  return java_lang_Class::is_primitive(mirror);
+JRT_END
+
 JRT_ENTRY(void, Runtime1::predicate_failed_trap(JavaThread* thread))
   ResourceMark rm;
 
   assert(!TieredCompilation, "incompatible with tiered compilation");
 
< prev index next >