1 //===-- ARMMCAsmInfo.cpp - ARM asm properties -----------------------------===// 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 contains the declarations of the ARMMCAsmInfo properties. 11 // 12 //===----------------------------------------------------------------------===// 13 14 #include "ARMMCAsmInfo.h" 15 #include "llvm/Support/CommandLine.h" 16 17 using namespace llvm; 18 19 // ARM EHABI is experimental but the quality is good enough 20 // to be turned on by default on non-Darwin ARM targets. 21 cl::opt<bool> 22 DisableARMEHABI("arm-disable-ehabi", cl::Hidden, 23 cl::desc("Disable ARM experimental exception handling"), 24 cl::init(false)); 25 26 27 void ARMMCAsmInfoDarwin::anchor() { } 28 29 ARMMCAsmInfoDarwin::ARMMCAsmInfoDarwin() { 30 Data64bitsDirective = 0; 31 CommentString = "@"; 32 Code16Directive = ".code\t16"; 33 Code32Directive = ".code\t32"; 34 UseDataRegionDirectives = true; 35 36 SupportsDebugInformation = true; 37 38 // Exceptions handling 39 ExceptionsType = ExceptionHandling::SjLj; 40 } 41 42 void ARMELFMCAsmInfo::anchor() { } 43 44 ARMELFMCAsmInfo::ARMELFMCAsmInfo() { 45 // ".comm align is in bytes but .align is pow-2." 46 AlignmentIsInBytes = false; 47 48 Data64bitsDirective = 0; 49 CommentString = "@"; 50 Code16Directive = ".code\t16"; 51 Code32Directive = ".code\t32"; 52 53 HasLEB128 = true; 54 SupportsDebugInformation = true; 55 56 // Exceptions handling 57 if (!DisableARMEHABI) 58 ExceptionsType = ExceptionHandling::ARM; 59 60 // foo(plt) instead of foo@plt 61 UseParensForSymbolVariant = true; 62 } 63