Re-commit: Demote EmitRawText call in AsmPrinter::EmitInlineAsm() and remove hasRawTe...
[oota-llvm.git] / lib / MC / MCAsmInfoDarwin.cpp
1 //===-- MCAsmInfoDarwin.cpp - Darwin asm properties -------------*- C++ -*-===//
2 //
3 //                     The LLVM Compiler Infrastructure
4 //
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9 //
10 // This file defines target asm properties related what form asm statements
11 // should take in general on Darwin-based targets
12 //
13 //===----------------------------------------------------------------------===//
14
15 #include "llvm/MC/MCAsmInfoDarwin.h"
16 #include "llvm/MC/MCContext.h"
17 #include "llvm/MC/MCExpr.h"
18 #include "llvm/MC/MCStreamer.h"
19 using namespace llvm;
20
21 void MCAsmInfoDarwin::anchor() { }
22
23 MCAsmInfoDarwin::MCAsmInfoDarwin() {
24   // Common settings for all Darwin targets.
25   // Syntax:
26   HasSingleParameterDotFile = false;
27   HasSubsectionsViaSymbols = true;
28
29   AlignmentIsInBytes = false;
30   COMMDirectiveAlignmentIsInBytes = false;
31   LCOMMDirectiveAlignmentType = LCOMM::Log2Alignment;
32   InlineAsmStart = " InlineAsm Start";
33   InlineAsmEnd = " InlineAsm End";
34
35   // Directives:
36   HasWeakDefDirective = true;
37   HasWeakDefCanBeHiddenDirective = true;
38   WeakRefDirective = "\t.weak_reference ";
39   ZeroDirective = "\t.space\t";  // ".space N" emits N zeros.
40   HasMachoZeroFillDirective = true;  // Uses .zerofill
41   HasMachoTBSSDirective = true; // Uses .tbss
42   HasStaticCtorDtorReferenceInStaticMode = true;
43
44   // FIXME: Darwin 10 and newer don't need this.
45   LinkerRequiresNonEmptyDwarfLines = true;
46
47   // FIXME: Change this once MC is the system assembler.
48   HasAggressiveSymbolFolding = false;
49
50   HiddenVisibilityAttr = MCSA_PrivateExtern;
51   HiddenDeclarationVisibilityAttr = MCSA_Invalid;
52
53   // Doesn't support protected visibility.
54   ProtectedVisibilityAttr = MCSA_Invalid;
55
56   HasDotTypeDotSizeDirective = false;
57   HasNoDeadStrip = true;
58
59   DwarfUsesRelocationsAcrossSections = false;
60
61   UseIntegratedAssembler = true;
62 }