src/cpu/ppc/vm/stubRoutines_ppc_64.hpp

Mon, 24 Sep 2018 17:18:38 -0400

author
gromero
date
Mon, 24 Sep 2018 17:18:38 -0400
changeset 9496
bcccbecdde63
parent 0
f90c822e73f8
child 9497
f892c3b6b651
permissions
-rw-r--r--

8131048: ppc implement CRC32 intrinsic
Reviewed-by: goetz

aoqi@0 1 /*
gromero@9496 2 * Copyright (c) 2002, 2018, Oracle and/or its affiliates. All rights reserved.
gromero@9496 3 * Copyright (c) 2012, 2018 SAP SE. All rights reserved.
aoqi@0 4 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
aoqi@0 5 *
aoqi@0 6 * This code is free software; you can redistribute it and/or modify it
aoqi@0 7 * under the terms of the GNU General Public License version 2 only, as
aoqi@0 8 * published by the Free Software Foundation.
aoqi@0 9 *
aoqi@0 10 * This code is distributed in the hope that it will be useful, but WITHOUT
aoqi@0 11 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
aoqi@0 12 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
aoqi@0 13 * version 2 for more details (a copy is included in the LICENSE file that
aoqi@0 14 * accompanied this code).
aoqi@0 15 *
aoqi@0 16 * You should have received a copy of the GNU General Public License version
aoqi@0 17 * 2 along with this work; if not, write to the Free Software Foundation,
aoqi@0 18 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
aoqi@0 19 *
aoqi@0 20 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
aoqi@0 21 * or visit www.oracle.com if you need additional information or have any
aoqi@0 22 * questions.
aoqi@0 23 *
aoqi@0 24 */
aoqi@0 25
aoqi@0 26 #ifndef CPU_PPC_VM_STUBROUTINES_PPC_64_HPP
aoqi@0 27 #define CPU_PPC_VM_STUBROUTINES_PPC_64_HPP
aoqi@0 28
aoqi@0 29 // This file holds the platform specific parts of the StubRoutines
aoqi@0 30 // definition. See stubRoutines.hpp for a description on how to
aoqi@0 31 // extend it.
aoqi@0 32
gromero@9496 33 static bool returns_to_call_stub(address return_pc) { return return_pc == _call_stub_return_address; }
aoqi@0 34
aoqi@0 35 enum platform_dependent_constants {
aoqi@0 36 code_size1 = 20000, // simply increase if too small (assembler will crash if too small)
aoqi@0 37 code_size2 = 20000 // simply increase if too small (assembler will crash if too small)
aoqi@0 38 };
aoqi@0 39
gromero@9496 40 // CRC32 Intrinsics.
gromero@9496 41 #define CRC32_COLUMN_SIZE 256
gromero@9496 42 #define CRC32_BYFOUR
gromero@9496 43 #ifdef CRC32_BYFOUR
gromero@9496 44 #define CRC32_TABLES 8
gromero@9496 45 #else
gromero@9496 46 #define CRC32_TABLES 1
gromero@9496 47 #endif
gromero@9496 48
gromero@9496 49 class ppc64 {
gromero@9496 50 friend class StubGenerator;
gromero@9496 51
gromero@9496 52 private:
gromero@9496 53
gromero@9496 54 // CRC32 Intrinsics.
gromero@9496 55 static juint _crc_table[CRC32_TABLES][CRC32_COLUMN_SIZE];
gromero@9496 56
gromero@9496 57 public:
gromero@9496 58
gromero@9496 59 // CRC32 Intrinsics.
gromero@9496 60 static void generate_load_crc_table_addr(MacroAssembler* masm, Register table);
gromero@9496 61
gromero@9496 62 };
gromero@9496 63
aoqi@0 64 #endif // CPU_PPC_VM_STUBROUTINES_PPC_64_HPP

mercurial