879 const Type** fields = TypeTuple::fields(argcnt); 880 int argp = TypeFunc::Parms; 881 fields[argp++] = TypePtr::NOTNULL; // src 882 fields[argp++] = TypePtr::NOTNULL; // dest 883 fields[argp++] = TypePtr::NOTNULL; // k array 884 fields[argp++] = TypePtr::NOTNULL; // r array 885 fields[argp++] = TypeInt::INT; // src len 886 if (Matcher::pass_original_key_for_aes()) { 887 fields[argp++] = TypePtr::NOTNULL; // original k array 888 } 889 assert(argp == TypeFunc::Parms+argcnt, "correct decoding"); 890 const TypeTuple* domain = TypeTuple::make(TypeFunc::Parms+argcnt, fields); 891 892 // returning cipher len (int) 893 fields = TypeTuple::fields(1); 894 fields[TypeFunc::Parms+0] = TypeInt::INT; 895 const TypeTuple* range = TypeTuple::make(TypeFunc::Parms+1, fields); 896 return TypeFunc::make(domain, range); 897 } 898 899 //------------- Interpreter state access for on stack replacement 900 const TypeFunc* OptoRuntime::osr_end_Type() { 901 // create input type (domain) 902 const Type **fields = TypeTuple::fields(1); 903 fields[TypeFunc::Parms+0] = TypeRawPtr::BOTTOM; // OSR temp buf 904 const TypeTuple *domain = TypeTuple::make(TypeFunc::Parms+1, fields); 905 906 // create result type 907 fields = TypeTuple::fields(1); 908 // fields[TypeFunc::Parms+0] = TypeInstPtr::NOTNULL; // locked oop 909 fields[TypeFunc::Parms+0] = NULL; // void 910 const TypeTuple *range = TypeTuple::make(TypeFunc::Parms, fields); 911 return TypeFunc::make(domain, range); 912 } 913 914 //-------------- methodData update helpers 915 916 const TypeFunc* OptoRuntime::profile_receiver_type_Type() { 917 // create input type (domain) 918 const Type **fields = TypeTuple::fields(2); | 879 const Type** fields = TypeTuple::fields(argcnt); 880 int argp = TypeFunc::Parms; 881 fields[argp++] = TypePtr::NOTNULL; // src 882 fields[argp++] = TypePtr::NOTNULL; // dest 883 fields[argp++] = TypePtr::NOTNULL; // k array 884 fields[argp++] = TypePtr::NOTNULL; // r array 885 fields[argp++] = TypeInt::INT; // src len 886 if (Matcher::pass_original_key_for_aes()) { 887 fields[argp++] = TypePtr::NOTNULL; // original k array 888 } 889 assert(argp == TypeFunc::Parms+argcnt, "correct decoding"); 890 const TypeTuple* domain = TypeTuple::make(TypeFunc::Parms+argcnt, fields); 891 892 // returning cipher len (int) 893 fields = TypeTuple::fields(1); 894 fields[TypeFunc::Parms+0] = TypeInt::INT; 895 const TypeTuple* range = TypeTuple::make(TypeFunc::Parms+1, fields); 896 return TypeFunc::make(domain, range); 897 } 898 899 /* 900 * void implCompress(byte[] buf, int ofs) 901 */ 902 const TypeFunc* OptoRuntime::sha_implCompress_Type() { 903 // create input type (domain) 904 int num_args = 2; 905 int argcnt = num_args; 906 const Type** fields = TypeTuple::fields(argcnt); 907 int argp = TypeFunc::Parms; 908 fields[argp++] = TypePtr::NOTNULL; // buf 909 fields[argp++] = TypePtr::NOTNULL; // state 910 assert(argp == TypeFunc::Parms+argcnt, "correct decoding"); 911 const TypeTuple* domain = TypeTuple::make(TypeFunc::Parms+argcnt, fields); 912 913 // no result type needed 914 fields = TypeTuple::fields(1); 915 fields[TypeFunc::Parms+0] = NULL; // void 916 const TypeTuple* range = TypeTuple::make(TypeFunc::Parms, fields); 917 return TypeFunc::make(domain, range); 918 } 919 920 /* 921 * int implCompressMultiBlock(byte[] b, int ofs, int limit) 922 */ 923 const TypeFunc* OptoRuntime::digestBase_implCompressMB_Type() { 924 // create input type (domain) 925 int num_args = 4; 926 int argcnt = num_args; 927 const Type** fields = TypeTuple::fields(argcnt); 928 int argp = TypeFunc::Parms; 929 fields[argp++] = TypePtr::NOTNULL; // buf 930 fields[argp++] = TypePtr::NOTNULL; // state 931 fields[argp++] = TypeInt::INT; // ofs 932 fields[argp++] = TypeInt::INT; // limit 933 assert(argp == TypeFunc::Parms+argcnt, "correct decoding"); 934 const TypeTuple* domain = TypeTuple::make(TypeFunc::Parms+argcnt, fields); 935 936 // returning ofs (int) 937 fields = TypeTuple::fields(1); 938 fields[TypeFunc::Parms+0] = TypeInt::INT; // ofs 939 const TypeTuple* range = TypeTuple::make(TypeFunc::Parms+1, fields); 940 return TypeFunc::make(domain, range); 941 } 942 943 //------------- Interpreter state access for on stack replacement 944 const TypeFunc* OptoRuntime::osr_end_Type() { 945 // create input type (domain) 946 const Type **fields = TypeTuple::fields(1); 947 fields[TypeFunc::Parms+0] = TypeRawPtr::BOTTOM; // OSR temp buf 948 const TypeTuple *domain = TypeTuple::make(TypeFunc::Parms+1, fields); 949 950 // create result type 951 fields = TypeTuple::fields(1); 952 // fields[TypeFunc::Parms+0] = TypeInstPtr::NOTNULL; // locked oop 953 fields[TypeFunc::Parms+0] = NULL; // void 954 const TypeTuple *range = TypeTuple::make(TypeFunc::Parms, fields); 955 return TypeFunc::make(domain, range); 956 } 957 958 //-------------- methodData update helpers 959 960 const TypeFunc* OptoRuntime::profile_receiver_type_Type() { 961 // create input type (domain) 962 const Type **fields = TypeTuple::fields(2); |