Top


定義場所(file name)

hotspot/src/share/vm/prims/nativeLookup.cpp

名前(function name)

address NativeLookup::base_library_lookup(const char* class_name, const char* method_name, const char* signature) {

本体部(body)

      EXCEPTION_MARK;
      bool in_base_library = true;  // SharedRuntime inits some math methods.
      TempNewSymbol c_name = SymbolTable::new_symbol(class_name,  CATCH);
      TempNewSymbol m_name = SymbolTable::new_symbol(method_name, CATCH);
      TempNewSymbol s_name = SymbolTable::new_symbol(signature,   CATCH);

  {- -------------------------------------------
  (1) NativeLookup::lookup() でリンク処理を行う.
      ---------------------------------------- -}

      // Find the class
      klassOop k = SystemDictionary::resolve_or_fail(c_name, true, CATCH);
      instanceKlassHandle klass (THREAD, k);

      // Find method and invoke standard lookup
      methodHandle method (THREAD,
                           klass->uncached_lookup_method(m_name, s_name));
      address result = lookup(method, in_base_library, CATCH);

  {- -------------------------------------------
  (1) (assert 処理)
      (NativeLookup::lookup() 内で in_base_library が false に変更されていたら, base library 内になかったということなので, assert failure)
      ---------------------------------------- -}

      assert(in_base_library, "must be in basic library");
      guarantee(result != NULL, "must be non NULL");

  {- -------------------------------------------
  (1) リターン
      ---------------------------------------- -}

      return result;
    }

This document is available under the GNU GENERAL PUBLIC LICENSE Version 2.