--- /dev/null 2018-09-25 19:25:27.000000000 +0300 +++ new/src/hotspot/cpu/aarch32/stubRoutines_aarch32.hpp 2018-09-25 19:25:27.000000000 +0300 @@ -0,0 +1,120 @@ +/* + * Copyright (c) 2003, 2011, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2014, Red Hat Inc. All rights reserved. + * Copyright (c) 2015, Linaro Ltd. All rights reserved. + * Copyright (c) 2015-2018, Azul Systems, Inc. All rights reserved. + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * This code is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 only, as + * published by the Free Software Foundation. + * + * This code is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + * version 2 for more details (a copy is included in the LICENSE file that + * accompanied this code). + * + * You should have received a copy of the GNU General Public License version + * 2 along with this work; if not, write to the Free Software Foundation, + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. + * + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA + * or visit www.oracle.com if you need additional information or have any + * questions. + * + */ + +#ifndef CPU_AARCH32_VM_STUBROUTINES_AARCH32_HPP +#define CPU_AARCH32_VM_STUBROUTINES_AARCH32_HPP + +// This file holds the platform specific parts of the StubRoutines +// definition. See stubRoutines.hpp for a description on how to +// extend it. + +// n.b. if we are notifying entry/exit to the simulator then the call +// stub does a notify at normal return placing +// call_stub_return_address one instruction beyond the notify. the +// latter address is sued by the stack unwind code when doign an +// exception return. +static bool returns_to_call_stub(address return_pc) { + return return_pc == _call_stub_return_address; +} + +enum platform_dependent_constants { + code_size1 = 19000, // simply increase if too small (assembler will crash if too small) + code_size2 = 22000 // simply increase if too small (assembler will crash if too small) +}; + +class aarch32 { + friend class StubGenerator; + + private: +#ifdef COMPILER2 + static address _idiv_entry; + static address _irem_entry; + static address _partial_subtype_check; + static address _string_compress_neon; + static address _string_inflate_neon; +#endif + + public: + +#ifdef COMPILER2 + static address idiv_entry() { + return _idiv_entry; + } + + static address irem_entry() { + return _irem_entry; + } + + static address partial_subtype_check() { + return _partial_subtype_check; + } + + static address string_compress_neon() { + return _string_compress_neon; + } + + static address string_inflate_neon() { + return _string_inflate_neon; + } +#endif + + private: + static juint _crc_table[]; + static juint _crc32c_table[]; + + private: + static juint _aes_te_table[]; + static juint _aes_td_table[]; + + private: + static juint _sha1_table[]; + static juint _sha256_table[]; + static julong _sha512_table[]; +}; + + + static address _cipherBlockChaining_encryptAESCrypt_special; + static address _cipherBlockChaining_decryptAESCrypt_special; + + static address _aes_table_te_addr; + static address _aes_table_td_addr; + + static address _sha1_table_addr; + static address _sha256_table_addr; + static address _sha512_table_addr; + +public: + static address cipherBlockChaining_encryptAESCrypt_special() { return _cipherBlockChaining_encryptAESCrypt_special; } + static address cipherBlockChaining_decryptAESCrypt_special() { return _cipherBlockChaining_decryptAESCrypt_special; } + static address aes_table_te_addr() { return _aes_table_te_addr; } + static address aes_table_td_addr() { return _aes_table_td_addr; } + + static address sha1_table_addr() { return _sha1_table_addr; } + static address sha256_table_addr() { return _sha256_table_addr; } + static address sha512_table_addr() { return _sha512_table_addr; } + +#endif // CPU_AARCH32_VM_STUBROUTINES_AARCH32_HPP