865
866 bool returns_long() const { return tf()->return_type() == T_LONG; }
867 bool return_value_is_used() const;
868
869 // Similar to cousin class CallNode::returns_pointer
870 bool returns_pointer() const;
871
872 #ifndef PRODUCT
873 virtual void dump_spec(outputStream *st) const;
874 #endif
875 };
876
877 //------------------------------MachCallJavaNode------------------------------
878 // "Base" class for machine-specific versions of subroutine calls
879 class MachCallJavaNode : public MachCallNode {
880 protected:
881 virtual uint cmp( const Node &n ) const;
882 virtual uint size_of() const; // Size is bigger
883 public:
884 ciMethod* _method; // Method being direct called
885 int _bci; // Byte Code index of call byte code
886 bool _optimized_virtual; // Tells if node is a static call or an optimized virtual
887 bool _method_handle_invoke; // Tells if the call has to preserve SP
888 MachCallJavaNode() : MachCallNode() {
889 init_class_id(Class_MachCallJava);
890 }
891
892 virtual const RegMask &in_RegMask(uint) const;
893
894 #ifndef PRODUCT
895 virtual void dump_spec(outputStream *st) const;
896 #endif
897 };
898
899 //------------------------------MachCallStaticJavaNode------------------------
900 // Machine-specific versions of monomorphic subroutine calls
901 class MachCallStaticJavaNode : public MachCallJavaNode {
902 virtual uint cmp( const Node &n ) const;
903 virtual uint size_of() const; // Size is bigger
904 public:
905 const char *_name; // Runtime wrapper name
906 MachCallStaticJavaNode() : MachCallJavaNode() {
907 init_class_id(Class_MachCallStaticJava);
908 }
909
910 // If this is an uncommon trap, return the request code, else zero.
911 int uncommon_trap_request() const;
912
913 virtual int ret_addr_offset();
|
865
866 bool returns_long() const { return tf()->return_type() == T_LONG; }
867 bool return_value_is_used() const;
868
869 // Similar to cousin class CallNode::returns_pointer
870 bool returns_pointer() const;
871
872 #ifndef PRODUCT
873 virtual void dump_spec(outputStream *st) const;
874 #endif
875 };
876
877 //------------------------------MachCallJavaNode------------------------------
878 // "Base" class for machine-specific versions of subroutine calls
879 class MachCallJavaNode : public MachCallNode {
880 protected:
881 virtual uint cmp( const Node &n ) const;
882 virtual uint size_of() const; // Size is bigger
883 public:
884 ciMethod* _method; // Method being direct called
885 bool _override_symbolic_info; // Override symbolic call site info from bytecode
886 int _bci; // Byte Code index of call byte code
887 bool _optimized_virtual; // Tells if node is a static call or an optimized virtual
888 bool _method_handle_invoke; // Tells if the call has to preserve SP
889 MachCallJavaNode() : MachCallNode(), _override_symbolic_info(false) {
890 init_class_id(Class_MachCallJava);
891 }
892
893 virtual const RegMask &in_RegMask(uint) const;
894
895 int resolved_method_index(CodeBuffer &cbuf) const {
896 if (_override_symbolic_info) {
897 // Attach corresponding Method* to the call site, so VM can use it during resolution
898 // instead of querying symbolic info from bytecode.
899 assert(_method != NULL, "method should be set");
900 assert(_method->constant_encoding()->is_method(), "should point to a Method");
901 return cbuf.oop_recorder()->find_index(_method->constant_encoding());
902 }
903 return 0; // Use symbolic info from bytecode (resolved_method == NULL).
904 }
905
906 #ifndef PRODUCT
907 virtual void dump_spec(outputStream *st) const;
908 #endif
909 };
910
911 //------------------------------MachCallStaticJavaNode------------------------
912 // Machine-specific versions of monomorphic subroutine calls
913 class MachCallStaticJavaNode : public MachCallJavaNode {
914 virtual uint cmp( const Node &n ) const;
915 virtual uint size_of() const; // Size is bigger
916 public:
917 const char *_name; // Runtime wrapper name
918 MachCallStaticJavaNode() : MachCallJavaNode() {
919 init_class_id(Class_MachCallStaticJava);
920 }
921
922 // If this is an uncommon trap, return the request code, else zero.
923 int uncommon_trap_request() const;
924
925 virtual int ret_addr_offset();
|