ARMMCAsmInfo.cpp revision 224133
167754Smsmith//===-- ARMMCAsmInfo.cpp - ARM asm properties -------------------*- C++ -*-===// 267754Smsmith// 367754Smsmith// The LLVM Compiler Infrastructure 469746Smsmith// 567754Smsmith// This file is distributed under the University of Illinois Open Source 667754Smsmith// License. See LICENSE.TXT for details. 767754Smsmith// 867754Smsmith//===----------------------------------------------------------------------===// 967754Smsmith// 1067754Smsmith// This file contains the declarations of the ARMMCAsmInfo properties. 1167754Smsmith// 1267754Smsmith//===----------------------------------------------------------------------===// 1367754Smsmith 1467754Smsmith#include "ARMMCAsmInfo.h" 1567754Smsmith#include "llvm/Support/CommandLine.h" 1667754Smsmith 1767754Smsmithusing namespace llvm; 1867754Smsmith 1967754Smsmithcl::opt<bool> 2067754SmsmithEnableARMEHABI("arm-enable-ehabi", cl::Hidden, 2167754Smsmith cl::desc("Generate ARM EHABI tables"), 2267754Smsmith cl::init(false)); 2367754Smsmith 2467754Smsmith 2567754Smsmithstatic const char *const arm_asm_table[] = { 2667754Smsmith "{r0}", "r0", 2767754Smsmith "{r1}", "r1", 2867754Smsmith "{r2}", "r2", 2967754Smsmith "{r3}", "r3", 3067754Smsmith "{r4}", "r4", 3167754Smsmith "{r5}", "r5", 3267754Smsmith "{r6}", "r6", 3367754Smsmith "{r7}", "r7", 3467754Smsmith "{r8}", "r8", 3567754Smsmith "{r9}", "r9", 3667754Smsmith "{r10}", "r10", 3767754Smsmith "{r11}", "r11", 3867754Smsmith "{r12}", "r12", 3967754Smsmith "{r13}", "r13", 4067754Smsmith "{r14}", "r14", 4167754Smsmith "{lr}", "lr", 4267754Smsmith "{sp}", "sp", 4367754Smsmith "{ip}", "ip", 4467754Smsmith "{fp}", "fp", 4567754Smsmith "{sl}", "sl", 4667754Smsmith "{memory}", "memory", 4767754Smsmith "{cc}", "cc", 4867754Smsmith 0,0 4967754Smsmith}; 5067754Smsmith 5167754SmsmithARMMCAsmInfoDarwin::ARMMCAsmInfoDarwin() { 5267754Smsmith AsmTransCBE = arm_asm_table; 5367754Smsmith Data64bitsDirective = 0; 5467754Smsmith CommentString = "@"; 5567754Smsmith SupportsDebugInformation = true; 5667754Smsmith 5767754Smsmith // Exceptions handling 5867754Smsmith ExceptionsType = ExceptionHandling::SjLj; 5967754Smsmith} 6067754Smsmith 6167754SmsmithARMELFMCAsmInfo::ARMELFMCAsmInfo() { 6267754Smsmith // ".comm align is in bytes but .align is pow-2." 6367754Smsmith AlignmentIsInBytes = false; 6467754Smsmith 6567754Smsmith Data64bitsDirective = 0; 6667754Smsmith CommentString = "@"; 6767754Smsmith 6867754Smsmith HasLEB128 = true; 6967754Smsmith PrivateGlobalPrefix = ".L"; 7067754Smsmith WeakRefDirective = "\t.weak\t"; 7167754Smsmith HasLCOMMDirective = true; 7267754Smsmith 7367754Smsmith SupportsDebugInformation = true; 7467754Smsmith 7567754Smsmith // Exceptions handling 7667754Smsmith if (EnableARMEHABI) 7767754Smsmith ExceptionsType = ExceptionHandling::ARM; 7867754Smsmith} 7967754Smsmith