github.com/aergoio/aergo@v1.3.1/libtool/src/gmp-6.1.2/mpn/powerpc64/aix.m4 (about)

     1  divert(-1)
     2  dnl  m4 macros for AIX 64-bit assembly.
     3  
     4  dnl  Copyright 2000-2002, 2005, 2006, 2010, 2012 Free Software Foundation, Inc.
     5  
     6  dnl  This file is part of the GNU MP Library.
     7  dnl
     8  dnl  The GNU MP Library is free software; you can redistribute it and/or modify
     9  dnl  it under the terms of either:
    10  dnl
    11  dnl    * the GNU Lesser General Public License as published by the Free
    12  dnl      Software Foundation; either version 3 of the License, or (at your
    13  dnl      option) any later version.
    14  dnl
    15  dnl  or
    16  dnl
    17  dnl    * the GNU General Public License as published by the Free Software
    18  dnl      Foundation; either version 2 of the License, or (at your option) any
    19  dnl      later version.
    20  dnl
    21  dnl  or both in parallel, as here.
    22  dnl
    23  dnl  The GNU MP Library is distributed in the hope that it will be useful, but
    24  dnl  WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
    25  dnl  or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
    26  dnl  for more details.
    27  dnl
    28  dnl  You should have received copies of the GNU General Public License and the
    29  dnl  GNU Lesser General Public License along with the GNU MP Library.  If not,
    30  dnl  see https://www.gnu.org/licenses/.
    31  
    32  define(`ASM_START',
    33  	`.machine	"any"
    34  	.toc')
    35  
    36  dnl  Called: PROLOGUE_cpu(GSYM_PREFIX`'foo[,toc])
    37  dnl          EPILOGUE_cpu(GSYM_PREFIX`'foo)
    38  dnl
    39  dnl  Don't want ELF style .size in the epilogue.
    40  
    41  define(`PROLOGUE_cpu',
    42  m4_assert_numargs_range(1,2)
    43  `ifelse(`$2',toc,,
    44  `ifelse(`$2',,,`m4_error(`Unrecognised PROLOGUE parameter')')')dnl
    45  	.globl	$1
    46  	.globl	.$1
    47  	.csect	[DS], 3
    48  $1:
    49  	.llong	.$1, TOC[tc0], 0
    50  	.csect	.$1[PR], 6
    51  .$1:')
    52  
    53  define(`EPILOGUE_cpu',
    54  m4_assert_numargs(1)
    55  `')
    56  
    57  define(`TOC_ENTRY', `')
    58  
    59  define(`LEA',
    60  m4_assert_numargs(2)
    61  `define(`TOC_ENTRY',
    62  `	.toc
    63  ..$2:	.tc	$2[TC], $2')'
    64  	`ld	$1, ..$2(2)')
    65  
    66  define(`LEAL',
    67  m4_assert_numargs(2)
    68  `LEA($1,$2)')
    69  
    70  
    71  define(`EXTERN',
    72  m4_assert_numargs(1)
    73  `	.globl	$1')
    74  
    75  define(`EXTERN_FUNC',
    76  m4_assert_numargs(1)
    77  `	.globl	.$1')
    78  
    79  define(`DEF_OBJECT',
    80  m4_assert_numargs_range(1,2)
    81  `	.csect	[RO], 3
    82  	ALIGN(ifelse($#,1,2,$2))
    83  $1:
    84  ')
    85  
    86  define(`END_OBJECT',
    87  m4_assert_numargs(1))
    88  
    89  define(`CALL',
    90  	`bl	.$1
    91  	nop')
    92  
    93  define(`ASM_END', `TOC_ENTRY')
    94  
    95  undefine(`EXTRA_REGISTER')
    96  
    97  divert