]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/config/i386/att.h
Licensing changes to GPLv3 resp. GPLv3 with GCC Runtime Exception.
[thirdparty/gcc.git] / gcc / config / i386 / att.h
CommitLineData
af62e7d6 1/* Definitions for AT&T assembler syntax for the Intel 80386.
748086b7 2 Copyright (C) 1988, 1996, 2000, 2001, 2002, 2007, 2009
39ed301b 3 Free Software Foundation, Inc.
af62e7d6 4
e20285ad 5This file is part of GCC.
af62e7d6 6
e20285ad 7GCC is free software; you can redistribute it and/or modify
af62e7d6 8it under the terms of the GNU General Public License as published by
2f83c7d6 9the Free Software Foundation; either version 3, or (at your option)
af62e7d6
RS
10any later version.
11
e20285ad 12GCC is distributed in the hope that it will be useful,
af62e7d6
RS
13but WITHOUT ANY WARRANTY; without even the implied warranty of
14MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15GNU General Public License for more details.
16
748086b7
JJ
17Under Section 7 of GPL version 3, you are granted additional
18permissions described in the GCC Runtime Library Exception, version
193.1, as published by the Free Software Foundation.
20
21You should have received a copy of the GNU General Public License and
22a copy of the GCC Runtime Library Exception along with this program;
23see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
2f83c7d6 24<http://www.gnu.org/licenses/>. */
af62e7d6 25
af62e7d6
RS
26\f
27/* Define the syntax of instructions and addresses. */
28
29/* Prefix for internally generated assembler labels. */
30#define LPREFIX ".L"
31
32/* Assembler pseudos to introduce constants of various size. */
33
79b79064
RH
34#define ASM_SHORT "\t.value\t"
35#define ASM_LONG "\t.long\t"
d39ac0fd 36#define ASM_QUAD "\t.quad\t" /* Should not be used for 32bit compilation. */
af62e7d6
RS
37
38/* How to output an ASCII string constant. */
39
af17c030 40#undef ASM_OUTPUT_ASCII
9d955c3a 41#define ASM_OUTPUT_ASCII(FILE, PTR, SIZE) \
0b760f1e 42do \
9d955c3a
KG
43{ size_t i = 0, limit = (SIZE); \
44 while (i < limit) \
af62e7d6 45 { if (i%10 == 0) { if (i!=0) fprintf ((FILE), "\n"); \
301d03af 46 fputs ("\t.byte\t", (FILE)); } \
0b760f1e 47 else fprintf ((FILE), ","); \
9d955c3a 48 fprintf ((FILE), "0x%x", ((PTR)[i++] & 0377)) ;} \
0b760f1e
JVA
49 fprintf ((FILE), "\n"); \
50} while (0)
af62e7d6 51
57dd137f 52/* Output at beginning of assembler file. */
1bc7c5b6 53#define TARGET_ASM_FILE_START_FILE_DIRECTIVE true
57dd137f 54
af62e7d6
RS
55/* This is how to output an assembler line
56 that says to advance the location counter
57 to a multiple of 2**LOG bytes. */
58
59#define ASM_OUTPUT_ALIGN(FILE,LOG) \
60 if ((LOG)!=0) fprintf ((FILE), "\t.align %d\n", 1<<(LOG))
61
62/* This is how to output an assembler line
63 that says to advance the location counter by SIZE bytes. */
64
af17c030 65#undef ASM_OUTPUT_SKIP
af62e7d6 66#define ASM_OUTPUT_SKIP(FILE,SIZE) \
58e15542 67 fprintf ((FILE), "\t.set .,.+%u\n", (int)(SIZE))
af62e7d6
RS
68
69/* Can't use ASM_OUTPUT_SKIP in text section; it doesn't leave 0s. */
70
71#define ASM_NO_SKIP_IN_TEXT 1
af62e7d6
RS
72\f
73/* Define the syntax of labels and symbol definitions/declarations. */
74
402eec87
RH
75/* The prefix to add for compiler private assembler symbols. */
76#undef LOCAL_LABEL_PREFIX
77#define LOCAL_LABEL_PREFIX "."
78
af62e7d6
RS
79/* This is how to store into the string BUF
80 the symbol_ref name of an internal numbered label where
81 PREFIX is the class of label and NUM is the number within the class.
82 This is suitable for output with `assemble_name'. */
83
c377a590 84#undef ASM_GENERATE_INTERNAL_LABEL
af62e7d6 85#define ASM_GENERATE_INTERNAL_LABEL(BUF,PREFIX,NUMBER) \
e59f7d3d 86 sprintf ((BUF), "%s%s%ld", LOCAL_LABEL_PREFIX, (PREFIX), (long)(NUMBER))
af62e7d6 87
892a2d68 88/* The prefix to add to user-visible assembler symbols. */
07d4d67d 89
66dae892
RK
90#undef USER_LABEL_PREFIX
91#define USER_LABEL_PREFIX ""