1divert(-1) 2 3dnl m4 macros for ARM64 ELF assembler. 4 5dnl Copyright 2020 Free Software Foundation, Inc. 6 7dnl This file is part of the GNU MP Library. 8dnl 9dnl The GNU MP Library is free software; you can redistribute it and/or modify 10dnl it under the terms of either: 11dnl 12dnl * the GNU Lesser General Public License as published by the Free 13dnl Software Foundation; either version 3 of the License, or (at your 14dnl option) any later version. 15dnl 16dnl or 17dnl 18dnl * the GNU General Public License as published by the Free Software 19dnl Foundation; either version 2 of the License, or (at your option) any 20dnl later version. 21dnl 22dnl or both in parallel, as here. 23dnl 24dnl The GNU MP Library is distributed in the hope that it will be useful, but 25dnl WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY 26dnl or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 27dnl for more details. 28dnl 29dnl You should have received copies of the GNU General Public License and the 30dnl GNU Lesser General Public License along with the GNU MP Library. If not, 31dnl see https://www.gnu.org/licenses/. 32 33 34dnl Standard commenting is with @, the default m4 # is for constants and we 35dnl don't want to disable macro expansions in or after them. 36 37changecom 38 39 40dnl LEA_HI(reg,gmp_symbol), LEA_LO(reg,gmp_symbol) 41dnl 42dnl Load the address of gmp_symbol into a register. We split this into two 43dnl parts to allow separation for manual insn scheduling. 44 45ifdef(`PIC',`dnl 46define(`LEA_HI', `adrp $1, :got:$2')dnl 47define(`LEA_LO', `ldr $1, [$1, #:got_lo12:$2]')dnl 48',`dnl 49define(`LEA_HI', `adrp $1, $2')dnl 50define(`LEA_LO', `add $1, $1, :lo12:$2')dnl 51')dnl 52 53divert`'dnl 54