1 /*
2 * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved.
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
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 *
697 bool is_not_c2_compilable() const { return access_flags().is_not_c2_compilable(); }
698 void set_not_c2_compilable() { _access_flags.set_not_c2_compilable(); }
699
700 bool is_not_c1_osr_compilable() const { return is_not_c1_compilable(); } // don't waste an accessFlags bit
701 void set_not_c1_osr_compilable() { set_not_c1_compilable(); } // don't waste an accessFlags bit
702 bool is_not_c2_osr_compilable() const { return access_flags().is_not_c2_osr_compilable(); }
703 void set_not_c2_osr_compilable() { _access_flags.set_not_c2_osr_compilable(); }
704
705 // Background compilation support
706 bool queued_for_compilation() const { return access_flags().queued_for_compilation(); }
707 void set_queued_for_compilation() { _access_flags.set_queued_for_compilation(); }
708 void clear_queued_for_compilation() { _access_flags.clear_queued_for_compilation(); }
709
710 // Resolve all classes in signature, return 'true' if successful
711 static bool load_signature_classes(methodHandle m, TRAPS);
712
713 // Return if true if not all classes references in signature, including return type, has been loaded
714 static bool has_unloaded_classes_in_signature(methodHandle m, TRAPS);
715
716 // Printing
717 void print_short_name(outputStream* st = tty) /*PRODUCT_RETURN*/; // prints as klassname::methodname; Exposed so field engineers can debug VM
718 void print_name(outputStream* st = tty) PRODUCT_RETURN; // prints as "virtual void foo(int)"
719
720 // Helper routine used for method sorting
721 static void sort_methods(objArrayOop methods,
722 objArrayOop methods_annotations,
723 objArrayOop methods_parameter_annotations,
724 objArrayOop methods_default_annotations,
725 bool idempotent = false);
726
727 // size of parameters
728 void set_size_of_parameters(int size) { _size_of_parameters = size; }
729 private:
730
731 // Inlined elements
732 address* native_function_addr() const { assert(is_native(), "must be native"); return (address*) (this+1); }
733 address* signature_handler_addr() const { return native_function_addr() + 1; }
734
735 // Garbage collection support
736 oop* adr_constMethod() const { return (oop*)&_constMethod; }
737 oop* adr_method_data() const { return (oop*)&_method_data; }
738 };
|
1 /*
2 * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
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 *
697 bool is_not_c2_compilable() const { return access_flags().is_not_c2_compilable(); }
698 void set_not_c2_compilable() { _access_flags.set_not_c2_compilable(); }
699
700 bool is_not_c1_osr_compilable() const { return is_not_c1_compilable(); } // don't waste an accessFlags bit
701 void set_not_c1_osr_compilable() { set_not_c1_compilable(); } // don't waste an accessFlags bit
702 bool is_not_c2_osr_compilable() const { return access_flags().is_not_c2_osr_compilable(); }
703 void set_not_c2_osr_compilable() { _access_flags.set_not_c2_osr_compilable(); }
704
705 // Background compilation support
706 bool queued_for_compilation() const { return access_flags().queued_for_compilation(); }
707 void set_queued_for_compilation() { _access_flags.set_queued_for_compilation(); }
708 void clear_queued_for_compilation() { _access_flags.clear_queued_for_compilation(); }
709
710 // Resolve all classes in signature, return 'true' if successful
711 static bool load_signature_classes(methodHandle m, TRAPS);
712
713 // Return if true if not all classes references in signature, including return type, has been loaded
714 static bool has_unloaded_classes_in_signature(methodHandle m, TRAPS);
715
716 // Printing
717 void print_short_name(outputStream* st = tty); // prints as klassname::methodname; Exposed so field engineers can debug VM
718 void print_name(outputStream* st = tty); // prints as "virtual void foo(int)"; exposed for TraceRedefineClasses
719
720 // Helper routine used for method sorting
721 static void sort_methods(objArrayOop methods,
722 objArrayOop methods_annotations,
723 objArrayOop methods_parameter_annotations,
724 objArrayOop methods_default_annotations,
725 bool idempotent = false);
726
727 // size of parameters
728 void set_size_of_parameters(int size) { _size_of_parameters = size; }
729 private:
730
731 // Inlined elements
732 address* native_function_addr() const { assert(is_native(), "must be native"); return (address*) (this+1); }
733 address* signature_handler_addr() const { return native_function_addr() + 1; }
734
735 // Garbage collection support
736 oop* adr_constMethod() const { return (oop*)&_constMethod; }
737 oop* adr_method_data() const { return (oop*)&_method_data; }
738 };
|