xref: /netbsd-src/external/gpl3/gcc/dist/gcc/config/loongarch/loongarch-ftypes.def (revision b1e838363e3c6fc78a55519254d99869742dd33c)
1/* Definitions of prototypes for LoongArch built-in functions.
2   Copyright (C) 2021-2022 Free Software Foundation, Inc.
3   Contributed by Loongson Ltd.
4   Based on MIPS target for GNU ckompiler.
5
6This file is part of GCC.
7
8GCC is free software; you can redistribute it and/or modify
9it under the terms of the GNU General Public License as published by
10the Free Software Foundation; either version 3, or (at your option)
11any later version.
12
13GCC is distributed in the hope that it will be useful,
14but WITHOUT ANY WARRANTY; without even the implied warranty of
15MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16GNU General Public License for more details.
17
18You should have received a copy of the GNU General Public License
19along with GCC; see the file COPYING3.  If not see
20<http://www.gnu.org/licenses/>.  */
21
22/* Invoke DEF_LARCH_FTYPE (NARGS, LIST) for each prototype used by
23   LoongArch built-in functions, where:
24
25      NARGS is the number of arguments.
26      LIST contains the return-type code followed by the codes for each
27      argument type.
28
29   Argument- and return-type codes are either modes or one of the following:
30
31      VOID for void_type_node
32      INT for integer_type_node
33      POINTER for ptr_type_node
34
35   (we don't use PTR because that's a ANSI-compatibillity macro).
36
37   Please keep this list lexicographically sorted by the LIST argument.  */
38
39DEF_LARCH_FTYPE (1, (UQI, USI))
40DEF_LARCH_FTYPE (1, (UHI, USI))
41DEF_LARCH_FTYPE (1, (USI, USI))
42DEF_LARCH_FTYPE (1, (UDI, USI))
43DEF_LARCH_FTYPE (1, (USI, UQI))
44DEF_LARCH_FTYPE (1, (VOID, USI))
45
46DEF_LARCH_FTYPE (2, (VOID, UQI, USI))
47DEF_LARCH_FTYPE (2, (VOID, UHI, USI))
48DEF_LARCH_FTYPE (2, (VOID, USI, USI))
49DEF_LARCH_FTYPE (2, (VOID, UDI, USI))
50DEF_LARCH_FTYPE (2, (VOID, DI, UQI))
51DEF_LARCH_FTYPE (2, (VOID, SI, UQI))
52DEF_LARCH_FTYPE (2, (VOID, DI, DI))
53DEF_LARCH_FTYPE (2, (SI, SI, UQI))
54DEF_LARCH_FTYPE (2, (DI, DI, UQI))
55DEF_LARCH_FTYPE (2, (SI, QI, SI))
56DEF_LARCH_FTYPE (2, (SI, HI, SI))
57DEF_LARCH_FTYPE (2, (SI, SI, SI))
58DEF_LARCH_FTYPE (2, (SI, DI, SI))
59DEF_LARCH_FTYPE (2, (USI, USI, USI))
60DEF_LARCH_FTYPE (2, (UDI, UDI, USI))
61
62DEF_LARCH_FTYPE (3, (VOID, USI, USI, SI))
63DEF_LARCH_FTYPE (3, (VOID, USI, UDI, SI))
64DEF_LARCH_FTYPE (3, (USI, USI, USI, USI))
65DEF_LARCH_FTYPE (3, (UDI, UDI, UDI, USI))
66