Daily bump.
[official-gcc.git] / gcc / config / aarch64 / aarch64-coff.h
blob72607262e1ba830968bad3286f086185cceadec7
1 /* Machine description for AArch64 architecture.
2 Copyright (C) 2024-2025 Free Software Foundation, Inc.
4 This file is part of GCC.
6 GCC is free software; you can redistribute it and/or modify it
7 under the terms of the GNU General Public License as published by
8 the Free Software Foundation; either version 3, or (at your option)
9 any later version.
11 GCC is distributed in the hope that it will be useful, but
12 WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 General Public License for more details.
16 You should have received a copy of the GNU General Public License
17 along with GCC; see the file COPYING3. If not see
18 <http://www.gnu.org/licenses/>. */
20 #ifndef GCC_AARCH64_COFF_H
21 #define GCC_AARCH64_COFF_H
23 #undef LOCAL_LABEL_PREFIX
24 #define LOCAL_LABEL_PREFIX "."
26 /* Using long long breaks -ansi and -std=c90, so these will need to be
27 made conditional for an LLP64 ABI. */
28 #undef SIZE_TYPE
29 #define SIZE_TYPE "long long unsigned int"
31 #undef PTRDIFF_TYPE
32 #define PTRDIFF_TYPE "long long int"
34 #undef LONG_TYPE_SIZE
35 #define LONG_TYPE_SIZE 32
37 #ifndef ASM_GENERATE_INTERNAL_LABEL
38 # define ASM_GENERATE_INTERNAL_LABEL(STRING, PREFIX, NUM) \
39 sprintf (STRING, "*%s%s%u", LOCAL_LABEL_PREFIX, PREFIX, (unsigned int)(NUM))
40 #endif
42 #define ASM_OUTPUT_ALIGN(STREAM, POWER) \
43 fprintf (STREAM, "\t.align\t%d\n", (int)POWER)
45 /* Output a common block. */
46 #ifndef ASM_OUTPUT_COMMON
47 # define ASM_OUTPUT_COMMON(STREAM, NAME, SIZE, ROUNDED) \
48 { \
49 fprintf (STREAM, "\t.comm\t"); \
50 assemble_name (STREAM, NAME); \
51 asm_fprintf (STREAM, ", %d, %d\n", \
52 (int)(ROUNDED), (int)(SIZE)); \
54 #endif
56 #define ASM_OUTPUT_LOCAL(FILE, NAME, SIZE, ROUNDED) \
57 ( fputs (".lcomm ", (FILE)), \
58 assemble_name ((FILE), (NAME)), \
59 fprintf ((FILE), "," HOST_WIDE_INT_PRINT_UNSIGNED "\n", (ROUNDED)))
61 #define ASM_OUTPUT_SKIP(STREAM, NBYTES) \
62 fprintf (STREAM, "\t.space\t%d // skip\n", (int) (NBYTES))
64 /* Definitions that are not yet supported by binutils for the
65 aarch64-w64-mingw32 target. */
66 #define ASM_OUTPUT_TYPE_DIRECTIVE(STREAM, NAME, TYPE)
67 #define ASM_DECLARE_FUNCTION_SIZE(FILE, FNAME, DECL)
69 #define TEXT_SECTION_ASM_OP "\t.text"
70 #define DATA_SECTION_ASM_OP "\t.data"
71 #define BSS_SECTION_ASM_OP "\t.bss"
73 #define CTORS_SECTION_ASM_OP "\t.section\t.ctors, \"aw\""
74 #define DTORS_SECTION_ASM_OP "\t.section\t.dtors, \"aw\""
76 #define GLOBAL_ASM_OP "\t.global\t"
78 #undef SUPPORTS_INIT_PRIORITY
79 #define SUPPORTS_INIT_PRIORITY 0
81 #endif