src/hotspot/share/classfile/systemDictionary.hpp
changeset 48826 c4d9d1b08e2e
parent 48637 7bba05746c44
child 49037 dc68aeea4840
equal deleted inserted replaced
48825:ef8a98bc71f8 48826:c4d9d1b08e2e
    30 #include "jvmci/systemDictionary_jvmci.hpp"
    30 #include "jvmci/systemDictionary_jvmci.hpp"
    31 #include "oops/objArrayOop.hpp"
    31 #include "oops/objArrayOop.hpp"
    32 #include "oops/symbol.hpp"
    32 #include "oops/symbol.hpp"
    33 #include "runtime/java.hpp"
    33 #include "runtime/java.hpp"
    34 #include "runtime/reflectionUtils.hpp"
    34 #include "runtime/reflectionUtils.hpp"
       
    35 #include "runtime/signature.hpp"
    35 #include "utilities/hashtable.hpp"
    36 #include "utilities/hashtable.hpp"
    36 #include "utilities/hashtable.inline.hpp"
    37 #include "utilities/hashtable.inline.hpp"
    37 
    38 
    38 // The dictionary in each ClassLoaderData stores all loaded classes, either
    39 // The dictionary in each ClassLoaderData stores all loaded classes, either
    39 // initiatied by its class loader or defined by its class loader:
    40 // initiatied by its class loader or defined by its class loader:
   525   // for a given signature, find the internal MethodHandle method (linkTo* or invokeBasic)
   526   // for a given signature, find the internal MethodHandle method (linkTo* or invokeBasic)
   526   // (does not ask Java, since this is a low-level intrinsic defined by the JVM)
   527   // (does not ask Java, since this is a low-level intrinsic defined by the JVM)
   527   static methodHandle find_method_handle_intrinsic(vmIntrinsics::ID iid,
   528   static methodHandle find_method_handle_intrinsic(vmIntrinsics::ID iid,
   528                                                    Symbol* signature,
   529                                                    Symbol* signature,
   529                                                    TRAPS);
   530                                                    TRAPS);
       
   531 
       
   532   // compute java_mirror (java.lang.Class instance) for a type ("I", "[[B", "LFoo;", etc.)
       
   533   // Either the accessing_klass or the CL/PD can be non-null, but not both.
       
   534   static Handle    find_java_mirror_for_type(Symbol* signature,
       
   535                                              Klass* accessing_klass,
       
   536                                              Handle class_loader,
       
   537                                              Handle protection_domain,
       
   538                                              SignatureStream::FailureMode failure_mode,
       
   539                                              TRAPS);
       
   540   static Handle    find_java_mirror_for_type(Symbol* signature,
       
   541                                              Klass* accessing_klass,
       
   542                                              SignatureStream::FailureMode failure_mode,
       
   543                                              TRAPS) {
       
   544     // callee will fill in CL/PD from AK, if they are needed
       
   545     return find_java_mirror_for_type(signature, accessing_klass, Handle(), Handle(),
       
   546                                      failure_mode, THREAD);
       
   547   }
       
   548 
       
   549 
       
   550   // fast short-cut for the one-character case:
       
   551   static oop       find_java_mirror_for_type(char signature_char);
       
   552 
   530   // find a java.lang.invoke.MethodType object for a given signature
   553   // find a java.lang.invoke.MethodType object for a given signature
   531   // (asks Java to compute it if necessary, except in a compiler thread)
   554   // (asks Java to compute it if necessary, except in a compiler thread)
   532   static Handle    find_method_handle_type(Symbol* signature,
   555   static Handle    find_method_handle_type(Symbol* signature,
   533                                            Klass* accessing_klass,
   556                                            Klass* accessing_klass,
   534                                            TRAPS);
   557                                            TRAPS);
   544                                                Klass* callee,
   567                                                Klass* callee,
   545                                                Symbol* name,
   568                                                Symbol* name,
   546                                                Symbol* signature,
   569                                                Symbol* signature,
   547                                                TRAPS);
   570                                                TRAPS);
   548 
   571 
       
   572   // ask Java to compute a constant by invoking a BSM given a Dynamic_info CP entry
       
   573   static Handle    link_dynamic_constant(Klass* caller,
       
   574                                          int condy_index,
       
   575                                          Handle bootstrap_specifier,
       
   576                                          Symbol* name,
       
   577                                          Symbol* type,
       
   578                                          TRAPS);
       
   579 
   549   // ask Java to create a dynamic call site, while linking an invokedynamic op
   580   // ask Java to create a dynamic call site, while linking an invokedynamic op
   550   static methodHandle find_dynamic_call_site_invoker(Klass* caller,
   581   static methodHandle find_dynamic_call_site_invoker(Klass* caller,
       
   582                                                      int indy_index,
   551                                                      Handle bootstrap_method,
   583                                                      Handle bootstrap_method,
   552                                                      Symbol* name,
   584                                                      Symbol* name,
   553                                                      Symbol* type,
   585                                                      Symbol* type,
   554                                                      Handle *appendix_result,
   586                                                      Handle *appendix_result,
   555                                                      Handle *method_type_result,
   587                                                      Handle *method_type_result,