src/share/vm/ci/ciMethod.hpp

Print this page




   5  * This code is free software; you can redistribute it and/or modify it
   6  * under the terms of the GNU General Public License version 2 only, as
   7  * published by the Free Software Foundation.
   8  *
   9  * This code is distributed in the hope that it will be useful, but WITHOUT
  10  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  11  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  12  * version 2 for more details (a copy is included in the LICENSE file that
  13  * accompanied this code).
  14  *
  15  * You should have received a copy of the GNU General Public License version
  16  * 2 along with this work; if not, write to the Free Software Foundation,
  17  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  18  *
  19  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  20  * or visit www.oracle.com if you need additional information or have any
  21  * questions.
  22  *
  23  */
  24 











  25 class ciMethodBlocks;
  26 class MethodLiveness;
  27 class BitMap;
  28 class Arena;
  29 class BCEscapeAnalyzer;
  30 
  31 
  32 // ciMethod
  33 //
  34 // This class represents a methodOop in the HotSpot virtual
  35 // machine.
  36 class ciMethod : public ciObject {
  37   friend class CompileBroker;
  38   CI_PACKAGE_ACCESS
  39   friend class ciEnv;
  40   friend class ciExceptionHandlerStream;
  41   friend class ciBytecodeStream;
  42   friend class ciMethodHandle;
  43 
  44  private:


 252   bool is_initializer () const;
 253   bool can_be_statically_bound() const           { return _can_be_statically_bound; }
 254 
 255   // Print the bytecodes of this method.
 256   void print_codes_on(outputStream* st);
 257   void print_codes() {
 258     print_codes_on(tty);
 259   }
 260   void print_codes_on(int from, int to, outputStream* st);
 261 
 262   // Print the name of this method in various incarnations.
 263   void print_name(outputStream* st = tty);
 264   void print_short_name(outputStream* st = tty);
 265 
 266   methodOop get_method_handle_target() {
 267     klassOop receiver_limit_oop = NULL;
 268     int flags = 0;
 269     return MethodHandles::decode_method(get_oop(), receiver_limit_oop, flags);
 270   }
 271 };




   5  * This code is free software; you can redistribute it and/or modify it
   6  * under the terms of the GNU General Public License version 2 only, as
   7  * published by the Free Software Foundation.
   8  *
   9  * This code is distributed in the hope that it will be useful, but WITHOUT
  10  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  11  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  12  * version 2 for more details (a copy is included in the LICENSE file that
  13  * accompanied this code).
  14  *
  15  * You should have received a copy of the GNU General Public License version
  16  * 2 along with this work; if not, write to the Free Software Foundation,
  17  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  18  *
  19  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  20  * or visit www.oracle.com if you need additional information or have any
  21  * questions.
  22  *
  23  */
  24 
  25 #ifndef SHARE_VM_CI_CIMETHOD_HPP
  26 #define SHARE_VM_CI_CIMETHOD_HPP
  27 
  28 #include "ci/ciFlags.hpp"
  29 #include "ci/ciInstanceKlass.hpp"
  30 #include "ci/ciObject.hpp"
  31 #include "ci/ciSignature.hpp"
  32 #include "compiler/methodLiveness.hpp"
  33 #include "prims/methodHandles.hpp"
  34 #include "utilities/bitMap.hpp"
  35 
  36 class ciMethodBlocks;
  37 class MethodLiveness;
  38 class BitMap;
  39 class Arena;
  40 class BCEscapeAnalyzer;
  41 
  42 
  43 // ciMethod
  44 //
  45 // This class represents a methodOop in the HotSpot virtual
  46 // machine.
  47 class ciMethod : public ciObject {
  48   friend class CompileBroker;
  49   CI_PACKAGE_ACCESS
  50   friend class ciEnv;
  51   friend class ciExceptionHandlerStream;
  52   friend class ciBytecodeStream;
  53   friend class ciMethodHandle;
  54 
  55  private:


 263   bool is_initializer () const;
 264   bool can_be_statically_bound() const           { return _can_be_statically_bound; }
 265 
 266   // Print the bytecodes of this method.
 267   void print_codes_on(outputStream* st);
 268   void print_codes() {
 269     print_codes_on(tty);
 270   }
 271   void print_codes_on(int from, int to, outputStream* st);
 272 
 273   // Print the name of this method in various incarnations.
 274   void print_name(outputStream* st = tty);
 275   void print_short_name(outputStream* st = tty);
 276 
 277   methodOop get_method_handle_target() {
 278     klassOop receiver_limit_oop = NULL;
 279     int flags = 0;
 280     return MethodHandles::decode_method(get_oop(), receiver_limit_oop, flags);
 281   }
 282 };
 283 
 284 #endif // SHARE_VM_CI_CIMETHOD_HPP