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 = "_"; |
Rafael Espindola | 2e2563b | 2010-01-26 20:21:43 +0000 | [diff] [blame] | 21 | COMMDirectiveAlignmentIsInBytes = false; |
Chris Lattner | 9eb158d | 2010-01-23 07:47:02 +0000 | [diff] [blame] | 22 | HasLCOMMDirective = true; |
Chris Lattner | 40412e7 | 2009-07-27 16:45:59 +0000 | [diff] [blame] | 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 | 111a319 | 2010-01-26 23:51:52 +0000 | [diff] [blame] | 27 | LinkOnceDirective = "\t.linkonce discard\n"; |
Chris Lattner | 152a29b | 2010-01-23 06:53:23 +0000 | [diff] [blame] | 28 | |
| 29 | // Doesn't support visibility: |
| 30 | HiddenVisibilityAttr = ProtectedVisibilityAttr = MCSA_Invalid; |
Chris Lattner | 40412e7 | 2009-07-27 16:45:59 +0000 | [diff] [blame] | 31 | |
| 32 | // Set up DWARF directives |
| 33 | HasLEB128 = true; // Target asm supports leb128 directives (little-endian) |
| 34 | AbsoluteDebugSectionOffsets = true; |
| 35 | AbsoluteEHSectionOffsets = false; |
| 36 | SupportsDebugInformation = true; |
| 37 | DwarfSectionOffsetDirective = "\t.secrel32\t"; |
Chris Lattner | 40412e7 | 2009-07-27 16:45:59 +0000 | [diff] [blame] | 38 | } |