diff options
author | Torbjorn Granlund <tg@gmplib.org> | 2021-11-14 12:22:50 +0100 |
---|---|---|
committer | Torbjorn Granlund <tg@gmplib.org> | 2021-11-14 12:22:50 +0100 |
commit | 928ed2280f77ae1d4c0d5bf88635cf38b29f27f2 (patch) | |
tree | d2bfd361db25aa844c7c6bb4792b2a5f4475e4c3 /mpn | |
parent | 798fa2a7893ee32e047e3fc265effda43f77c71c (diff) | |
download | gmp-928ed2280f77ae1d4c0d5bf88635cf38b29f27f2.tar.gz |
Clean up Sparc 64-bit PIC while allowing old-style gdop-incapable environments.
Diffstat (limited to 'mpn')
-rw-r--r-- | mpn/sparc32/sparc-defs.m4 | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/mpn/sparc32/sparc-defs.m4 b/mpn/sparc32/sparc-defs.m4 index 33a0c535b..fff0ff8c1 100644 --- a/mpn/sparc32/sparc-defs.m4 +++ b/mpn/sparc32/sparc-defs.m4 @@ -3,7 +3,7 @@ divert(-1) dnl m4 macros for SPARC assembler (32 and 64 bit). -dnl Copyright 2002, 2011, 2013, 2017 Free Software Foundation, Inc. +dnl Copyright 2002, 2011, 2013, 2017, 2021 Free Software Foundation, Inc. dnl This file is part of the GNU MP Library. dnl @@ -74,16 +74,20 @@ dnl of one after the other. That might need one more scratch register. define(LEA64, m4_assert_numargs(3) -m4_assert_defined(`HAVE_GOTDATA') `ifdef(`PIC',` rd %pc, %`$2' sethi %hi(_GLOBAL_OFFSET_TABLE_+4), %`$3' add %`$3', %lo(_GLOBAL_OFFSET_TABLE_+8), %`$3' add %`$2', %`$3', %`$3' +ifelse(HAVE_GDOP,yes,` sethi %gdop_hix22(`$1'), %`$2' xor %`$2', %gdop_lox10(`$1'), %`$2' ldx [%`$3' + %`$2'], %`$2', %gdop(`$1') ',` + sethi %hi(`$1'), %`$2' + or %`$2', %lo(`$1'), %`$2' + ldx [%`$3' + %`$2'], %`$2' +')',` sethi %h44(`$1'), %`$2' or %`$2', %m44(`$1'), %`$2' sllx %`$2', 12, %`$2' |