Chris Lattner | 0545746 | 2009-08-22 21:03:30 +0000 | [diff] [blame] | 1 | //===-- MCAsmInfoCOFF.cpp - COFF asm properties -----------------*- C++ -*-===// |
Chris Lattner | 1814e81 | 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 | 7b26fce | 2009-08-22 20:48:53 +0000 | [diff] [blame] | 15 | #include "llvm/MC/MCAsmInfoCOFF.h" |
Chris Lattner | 1814e81 | 2009-07-27 16:45:59 +0000 | [diff] [blame] | 16 | using namespace llvm; |
| 17 | |
David Blaikie | a379b181 | 2011-12-20 02:50:00 +0000 | [diff] [blame] | 18 | void MCAsmInfoCOFF::anchor() { } |
| 19 | |
Chris Lattner | 2b4364f | 2010-01-20 06:34:14 +0000 | [diff] [blame] | 20 | MCAsmInfoCOFF::MCAsmInfoCOFF() { |
Benjamin Kramer | 68b9f05 | 2012-09-07 21:08:01 +0000 | [diff] [blame] | 21 | // MingW 4.5 and later support .comm with log2 alignment, but .lcomm uses byte |
| 22 | // alignment. |
| 23 | COMMDirectiveAlignmentIsInBytes = false; |
| 24 | LCOMMDirectiveAlignmentType = LCOMM::ByteAlignment; |
Chris Lattner | 1814e81 | 2009-07-27 16:45:59 +0000 | [diff] [blame] | 25 | HasDotTypeDotSizeDirective = false; |
| 26 | HasSingleParameterDotFile = false; |
Chris Lattner | 1814e81 | 2009-07-27 16:45:59 +0000 | [diff] [blame] | 27 | WeakRefDirective = "\t.weak\t"; |
Rafael Espindola | 04867ce | 2013-12-02 23:04:51 +0000 | [diff] [blame] | 28 | HasLinkOnceDirective = true; |
Jim Grosbach | dc1e36e | 2012-05-11 01:41:30 +0000 | [diff] [blame] | 29 | |
Chris Lattner | 0bfd279 | 2010-01-23 06:53:23 +0000 | [diff] [blame] | 30 | // Doesn't support visibility: |
Eli Friedman | 64a4bf1 | 2011-09-23 00:13:02 +0000 | [diff] [blame] | 31 | HiddenVisibilityAttr = HiddenDeclarationVisibilityAttr = MCSA_Invalid; |
| 32 | ProtectedVisibilityAttr = MCSA_Invalid; |
Chris Lattner | 1814e81 | 2009-07-27 16:45:59 +0000 | [diff] [blame] | 33 | |
| 34 | // Set up DWARF directives |
Chris Lattner | 1814e81 | 2009-07-27 16:45:59 +0000 | [diff] [blame] | 35 | SupportsDebugInformation = true; |
Matt Arsenault | 034ca0f | 2013-04-22 22:49:11 +0000 | [diff] [blame] | 36 | NeedsDwarfSectionOffsetDirective = true; |
Daniel Sanders | 753e176 | 2014-02-13 14:44:26 +0000 | [diff] [blame] | 37 | |
| 38 | UseIntegratedAssembler = true; |
Ahmed Bougacha | 1905287 | 2015-04-28 01:37:11 +0000 | [diff] [blame] | 39 | |
Ahmed Bougacha | 4a85643 | 2015-11-11 00:51:36 +0000 | [diff] [blame] | 40 | // At least MSVC inline-asm does AShr. |
Ahmed Bougacha | 1905287 | 2015-04-28 01:37:11 +0000 | [diff] [blame] | 41 | UseLogicalShr = false; |
Chris Lattner | 1814e81 | 2009-07-27 16:45:59 +0000 | [diff] [blame] | 42 | } |
Michael J. Spencer | de3a211 | 2011-11-29 18:00:06 +0000 | [diff] [blame] | 43 | |
David Blaikie | a379b181 | 2011-12-20 02:50:00 +0000 | [diff] [blame] | 44 | void MCAsmInfoMicrosoft::anchor() { } |
| 45 | |
Michael J. Spencer | de3a211 | 2011-11-29 18:00:06 +0000 | [diff] [blame] | 46 | MCAsmInfoMicrosoft::MCAsmInfoMicrosoft() { |
Michael J. Spencer | de3a211 | 2011-11-29 18:00:06 +0000 | [diff] [blame] | 47 | } |
| 48 | |
David Blaikie | a379b181 | 2011-12-20 02:50:00 +0000 | [diff] [blame] | 49 | void MCAsmInfoGNUCOFF::anchor() { } |
| 50 | |
Michael J. Spencer | de3a211 | 2011-11-29 18:00:06 +0000 | [diff] [blame] | 51 | MCAsmInfoGNUCOFF::MCAsmInfoGNUCOFF() { |
| 52 | |
| 53 | } |