src/share/vm/ci/ciMethod.hpp
Index Unified diffs Context diffs Sdiffs Patch New Old Previous File Next File c1-mdo-alloc-failure Sdiff src/share/vm/ci

src/share/vm/ci/ciMethod.hpp

Print this page




  89 
  90   ciMethod(methodHandle h_m);
  91   ciMethod(ciInstanceKlass* holder, ciSymbol* name, ciSymbol* signature);
  92 
  93   methodOop get_methodOop() const {
  94     methodOop m = (methodOop)get_oop();
  95     assert(m != NULL, "illegal use of unloaded method");
  96     return m;
  97   }
  98 
  99   oop loader() const                             { return _holder->loader(); }
 100 
 101   const char* type_string()                      { return "ciMethod"; }
 102 
 103   void print_impl(outputStream* st);
 104 
 105   void load_code();
 106 
 107   void check_is_loaded() const                   { assert(is_loaded(), "not loaded"); }
 108 
 109   void build_method_data(methodHandle h_m);
 110 
 111   void code_at_put(int bci, Bytecodes::Code code) {
 112     Bytecodes::check(code);
 113     assert(0 <= bci && bci < code_size(), "valid bci");
 114     address bcp = _code + bci;
 115     *bcp = code;
 116   }
 117 
 118  public:
 119   // Basic method information.
 120   ciFlags flags() const                          { check_is_loaded(); return _flags; }
 121   ciSymbol* name() const                         { return _name; }
 122   ciInstanceKlass* holder() const                { return _holder; }
 123   ciMethodData* method_data();

 124 
 125   // Signature information.
 126   ciSignature* signature() const                 { return _signature; }
 127   ciType*      return_type() const               { return _signature->return_type(); }
 128   int          arg_size_no_receiver() const      { return _signature->size(); }
 129   int          arg_size() const                  { return _signature->size() + (_flags.is_static() ? 0 : 1); }
 130 
 131   // Method code and related information.
 132   address code()                                 { if (_code == NULL) load_code(); return _code; }
 133   int code_size() const                          { check_is_loaded(); return _code_size; }
 134   int max_stack() const                          { check_is_loaded(); return _max_stack; }
 135   int max_locals() const                         { check_is_loaded(); return _max_locals; }
 136   vmIntrinsics::ID intrinsic_id() const          { check_is_loaded(); return _intrinsic_id; }
 137   bool has_exception_handlers() const            { check_is_loaded(); return _handler_count > 0; }
 138   int exception_table_length() const             { check_is_loaded(); return _handler_count; }
 139   int interpreter_invocation_count() const       { check_is_loaded(); return _interpreter_invocation_count; }
 140   int interpreter_throwout_count() const         { check_is_loaded(); return _interpreter_throwout_count; }
 141 
 142   int comp_level();
 143 


 213   bool will_link(ciKlass* accessing_klass,
 214                  ciKlass* declared_method_holder,
 215                  Bytecodes::Code bc);
 216   bool should_exclude();
 217   bool should_inline();
 218   bool should_not_inline();
 219   bool should_print_assembly();
 220   bool break_at_execute();
 221   bool has_option(const char *option);
 222   bool can_be_compiled();
 223   bool can_be_osr_compiled(int entry_bci);
 224   void set_not_compilable();
 225   bool has_compiled_code();
 226   int  instructions_size(int comp_level = CompLevel_any);
 227   void log_nmethod_identity(xmlStream* log);
 228   bool is_not_reached(int bci);
 229   bool was_executed_more_than(int times);
 230   bool has_unloaded_classes_in_signature();
 231   bool is_klass_loaded(int refinfo_index, bool must_be_resolved) const;
 232   bool check_call(int refinfo_index, bool is_static) const;
 233   void build_method_data();  // make sure it exists in the VM also
 234   int scale_count(int count, float prof_factor = 1.);  // make MDO count commensurate with IIC
 235 
 236   // JSR 292 support
 237   bool is_method_handle_invoke()  const;
 238   bool is_method_handle_adapter() const;
 239   ciInstance* method_handle_type();
 240 
 241   // What kind of ciObject is this?
 242   bool is_method()                               { return true; }
 243 
 244   // Java access flags
 245   bool is_public      () const                   { return flags().is_public(); }
 246   bool is_private     () const                   { return flags().is_private(); }
 247   bool is_protected   () const                   { return flags().is_protected(); }
 248   bool is_static      () const                   { return flags().is_static(); }
 249   bool is_final       () const                   { return flags().is_final(); }
 250   bool is_synchronized() const                   { return flags().is_synchronized(); }
 251   bool is_native      () const                   { return flags().is_native(); }
 252   bool is_interface   () const                   { return flags().is_interface(); }
 253   bool is_abstract    () const                   { return flags().is_abstract(); }




  89 
  90   ciMethod(methodHandle h_m);
  91   ciMethod(ciInstanceKlass* holder, ciSymbol* name, ciSymbol* signature);
  92 
  93   methodOop get_methodOop() const {
  94     methodOop m = (methodOop)get_oop();
  95     assert(m != NULL, "illegal use of unloaded method");
  96     return m;
  97   }
  98 
  99   oop loader() const                             { return _holder->loader(); }
 100 
 101   const char* type_string()                      { return "ciMethod"; }
 102 
 103   void print_impl(outputStream* st);
 104 
 105   void load_code();
 106 
 107   void check_is_loaded() const                   { assert(is_loaded(), "not loaded"); }
 108 
 109   bool build_method_data(methodHandle h_m);
 110 
 111   void code_at_put(int bci, Bytecodes::Code code) {
 112     Bytecodes::check(code);
 113     assert(0 <= bci && bci < code_size(), "valid bci");
 114     address bcp = _code + bci;
 115     *bcp = code;
 116   }
 117 
 118  public:
 119   // Basic method information.
 120   ciFlags flags() const                          { check_is_loaded(); return _flags; }
 121   ciSymbol* name() const                         { return _name; }
 122   ciInstanceKlass* holder() const                { return _holder; }
 123   ciMethodData* method_data();
 124   ciMethodData* method_data_or_null();
 125 
 126   // Signature information.
 127   ciSignature* signature() const                 { return _signature; }
 128   ciType*      return_type() const               { return _signature->return_type(); }
 129   int          arg_size_no_receiver() const      { return _signature->size(); }
 130   int          arg_size() const                  { return _signature->size() + (_flags.is_static() ? 0 : 1); }
 131 
 132   // Method code and related information.
 133   address code()                                 { if (_code == NULL) load_code(); return _code; }
 134   int code_size() const                          { check_is_loaded(); return _code_size; }
 135   int max_stack() const                          { check_is_loaded(); return _max_stack; }
 136   int max_locals() const                         { check_is_loaded(); return _max_locals; }
 137   vmIntrinsics::ID intrinsic_id() const          { check_is_loaded(); return _intrinsic_id; }
 138   bool has_exception_handlers() const            { check_is_loaded(); return _handler_count > 0; }
 139   int exception_table_length() const             { check_is_loaded(); return _handler_count; }
 140   int interpreter_invocation_count() const       { check_is_loaded(); return _interpreter_invocation_count; }
 141   int interpreter_throwout_count() const         { check_is_loaded(); return _interpreter_throwout_count; }
 142 
 143   int comp_level();
 144 


 214   bool will_link(ciKlass* accessing_klass,
 215                  ciKlass* declared_method_holder,
 216                  Bytecodes::Code bc);
 217   bool should_exclude();
 218   bool should_inline();
 219   bool should_not_inline();
 220   bool should_print_assembly();
 221   bool break_at_execute();
 222   bool has_option(const char *option);
 223   bool can_be_compiled();
 224   bool can_be_osr_compiled(int entry_bci);
 225   void set_not_compilable();
 226   bool has_compiled_code();
 227   int  instructions_size(int comp_level = CompLevel_any);
 228   void log_nmethod_identity(xmlStream* log);
 229   bool is_not_reached(int bci);
 230   bool was_executed_more_than(int times);
 231   bool has_unloaded_classes_in_signature();
 232   bool is_klass_loaded(int refinfo_index, bool must_be_resolved) const;
 233   bool check_call(int refinfo_index, bool is_static) const;
 234   bool build_method_data();  // make sure it exists in the VM also
 235   int scale_count(int count, float prof_factor = 1.);  // make MDO count commensurate with IIC
 236 
 237   // JSR 292 support
 238   bool is_method_handle_invoke()  const;
 239   bool is_method_handle_adapter() const;
 240   ciInstance* method_handle_type();
 241 
 242   // What kind of ciObject is this?
 243   bool is_method()                               { return true; }
 244 
 245   // Java access flags
 246   bool is_public      () const                   { return flags().is_public(); }
 247   bool is_private     () const                   { return flags().is_private(); }
 248   bool is_protected   () const                   { return flags().is_protected(); }
 249   bool is_static      () const                   { return flags().is_static(); }
 250   bool is_final       () const                   { return flags().is_final(); }
 251   bool is_synchronized() const                   { return flags().is_synchronized(); }
 252   bool is_native      () const                   { return flags().is_native(); }
 253   bool is_interface   () const                   { return flags().is_interface(); }
 254   bool is_abstract    () const                   { return flags().is_abstract(); }


src/share/vm/ci/ciMethod.hpp
Index Unified diffs Context diffs Sdiffs Patch New Old Previous File Next File