Chris Lattner | 2807afa | 2009-08-22 21:03:30 +0000 | [diff] [blame] | 1 | //===-- MCAsmInfoCOFF.cpp - COFF asm properties -----------------*- C++ -*-===// |
Chris Lattner | 40412e7 | 2009-07-27 16:45:59 +0000 | [diff] [blame] | 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 COFF-based targets |
| 12 | // |
| 13 | //===----------------------------------------------------------------------===// |
| 14 | |
Chris Lattner | af76e59 | 2009-08-22 20:48:53 +0000 | [diff] [blame] | 15 | #include "llvm/MC/MCAsmInfoCOFF.h" |
Chris Lattner | 40412e7 | 2009-07-27 16:45:59 +0000 | [diff] [blame] | 16 | #include "llvm/ADT/SmallVector.h" |
| 17 | using namespace llvm; |
| 18 | |
Chris Lattner | 8eeba35 | 2010-01-20 06:34:14 +0000 | [diff] [blame] | 19 | MCAsmInfoCOFF::MCAsmInfoCOFF() { |
Chris Lattner | 40412e7 | 2009-07-27 16:45:59 +0000 | [diff] [blame] | 20 | GlobalPrefix = "_"; |
| 21 | LCOMMDirective = "\t.lcomm\t"; |
| 22 | COMMDirectiveTakesAlignment = false; |
| 23 | HasDotTypeDotSizeDirective = false; |
| 24 | HasSingleParameterDotFile = false; |
Chris Lattner | 40412e7 | 2009-07-27 16:45:59 +0000 | [diff] [blame] | 25 | PrivateGlobalPrefix = "L"; // Prefix for private global symbols |
| 26 | WeakRefDirective = "\t.weak\t"; |
Chris Lattner | 41eb8b4 | 2010-01-19 05:08:13 +0000 | [diff] [blame] | 27 | LinkOnceDirective = "\t.linkonce same_size\n"; |
Chris Lattner | 40412e7 | 2009-07-27 16:45:59 +0000 | [diff] [blame] | 28 | SetDirective = "\t.set\t"; |
Chris Lattner | 152a29b | 2010-01-23 06:53:23 +0000 | [diff] [blame] | 29 | |
| 30 | // Doesn't support visibility: |
| 31 | HiddenVisibilityAttr = ProtectedVisibilityAttr = MCSA_Invalid; |
Chris Lattner | 40412e7 | 2009-07-27 16:45:59 +0000 | [diff] [blame] | 32 | |
| 33 | // Set up DWARF directives |
| 34 | HasLEB128 = true; // Target asm supports leb128 directives (little-endian) |
| 35 | AbsoluteDebugSectionOffsets = true; |
| 36 | AbsoluteEHSectionOffsets = false; |
| 37 | SupportsDebugInformation = true; |
| 38 | DwarfSectionOffsetDirective = "\t.secrel32\t"; |
Chris Lattner | 40412e7 | 2009-07-27 16:45:59 +0000 | [diff] [blame] | 39 | } |
| 40 | |