blob: 464ed1f5a7cf3bffed70f5130be27b32f9025baa [file] [log] [blame]
Jim Laskey8e8de8f2006-09-07 22:05:02 +00001//===-- ARMTargetAsmInfo.cpp - ARM asm properties ---------------*- C++ -*-===//
2//
3// The LLVM Compiler Infrastructure
4//
Chris Lattner4ee451d2007-12-29 20:36:04 +00005// This file is distributed under the University of Illinois Open Source
6// License. See LICENSE.TXT for details.
Jim Laskey8e8de8f2006-09-07 22:05:02 +00007//
8//===----------------------------------------------------------------------===//
9//
10// This file contains the declarations of the ARMTargetAsmInfo properties.
11//
12//===----------------------------------------------------------------------===//
13
14#include "ARMTargetAsmInfo.h"
Jim Laskey8e8de8f2006-09-07 22:05:02 +000015using namespace llvm;
16
Chris Lattner5f28ffe2009-08-11 22:14:59 +000017static const char *const arm_asm_table[] = {
Chris Lattnera93ca922009-06-18 23:41:35 +000018 "{r0}", "r0",
19 "{r1}", "r1",
20 "{r2}", "r2",
21 "{r3}", "r3",
22 "{r4}", "r4",
23 "{r5}", "r5",
24 "{r6}", "r6",
25 "{r7}", "r7",
26 "{r8}", "r8",
27 "{r9}", "r9",
28 "{r10}", "r10",
29 "{r11}", "r11",
30 "{r12}", "r12",
31 "{r13}", "r13",
32 "{r14}", "r14",
33 "{lr}", "lr",
34 "{sp}", "sp",
35 "{ip}", "ip",
36 "{fp}", "fp",
37 "{sl}", "sl",
38 "{memory}", "memory",
39 "{cc}", "cc",
40 0,0
41};
Lauro Ramos Venancio61718a62007-06-08 21:06:23 +000042
Chris Lattner24def372009-08-02 05:23:52 +000043ARMDarwinTargetAsmInfo::ARMDarwinTargetAsmInfo() {
Chris Lattner5f28ffe2009-08-11 22:14:59 +000044 AsmTransCBE = arm_asm_table;
45 AlignmentIsInBytes = false;
46 Data64bitsDirective = 0;
47 CommentString = "@";
48 COMMDirectiveTakesAlignment = false;
49 InlineAsmStart = "@ InlineAsm Start";
50 InlineAsmEnd = "@ InlineAsm End";
51
52
Anton Korobeynikov0f3cc652008-08-07 09:54:23 +000053 ZeroDirective = "\t.space\t";
54 ZeroFillDirective = "\t.zerofill\t"; // Uses .zerofill
55 SetDirective = "\t.set\t";
Anton Korobeynikov0f3cc652008-08-07 09:54:23 +000056 ProtectedDirective = NULL;
Anton Korobeynikov0f3cc652008-08-07 09:54:23 +000057 HasDotTypeDotSizeDirective = false;
Devang Patel14a55d92009-06-19 21:54:26 +000058 SupportsDebugInformation = true;
Jim Grosbach1b747ad2009-08-11 00:09:57 +000059
60 // Exceptions handling
61 ExceptionsType = ExceptionHandling::SjLj;
62 GlobalEHDirective = "\t.globl\t";
63 SupportsWeakOmittedEHFrame = false;
64 AbsoluteEHSectionOffsets = false;
Anton Korobeynikov0f3cc652008-08-07 09:54:23 +000065}
66
Chris Lattner24def372009-08-02 05:23:52 +000067ARMELFTargetAsmInfo::ARMELFTargetAsmInfo() {
Chris Lattner5f28ffe2009-08-11 22:14:59 +000068 AlignmentIsInBytes = false;
69 Data64bitsDirective = 0;
70 CommentString = "@";
71 COMMDirectiveTakesAlignment = false;
72 InlineAsmStart = "@ InlineAsm Start";
73 InlineAsmEnd = "@ InlineAsm End";
74
Anton Korobeynikov0f3cc652008-08-07 09:54:23 +000075 NeedsSet = false;
76 HasLEB128 = true;
77 AbsoluteDebugSectionOffsets = true;
Anton Korobeynikov0f3cc652008-08-07 09:54:23 +000078 PrivateGlobalPrefix = ".L";
79 WeakRefDirective = "\t.weak\t";
80 SetDirective = "\t.set\t";
Chris Lattnerc89ecc52009-08-11 22:06:07 +000081 LCOMMDirective = "\t.lcomm\t";
82
Anton Korobeynikov0f3cc652008-08-07 09:54:23 +000083 DwarfRequiresFrameSection = false;
Anton Korobeynikov0f3cc652008-08-07 09:54:23 +000084
Devang Patel14a55d92009-06-19 21:54:26 +000085 SupportsDebugInformation = true;
Anton Korobeynikov0f3cc652008-08-07 09:54:23 +000086}