blob: 5b9dd2009f8b2eed2ac0863f1794b447372f9d17 [file] [log] [blame]
Chris Lattner05457462009-08-22 21:03:30 +00001//===-- MCAsmInfoCOFF.cpp - COFF asm properties -----------------*- C++ -*-===//
Chris Lattner1814e812009-07-27 16:45:59 +00002//
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 Lattner7b26fce2009-08-22 20:48:53 +000015#include "llvm/MC/MCAsmInfoCOFF.h"
Chris Lattner1814e812009-07-27 16:45:59 +000016using namespace llvm;
17
David Blaikiea379b1812011-12-20 02:50:00 +000018void MCAsmInfoCOFF::anchor() { }
19
Chris Lattner2b4364f2010-01-20 06:34:14 +000020MCAsmInfoCOFF::MCAsmInfoCOFF() {
Benjamin Kramer68b9f052012-09-07 21:08:01 +000021 // MingW 4.5 and later support .comm with log2 alignment, but .lcomm uses byte
22 // alignment.
23 COMMDirectiveAlignmentIsInBytes = false;
24 LCOMMDirectiveAlignmentType = LCOMM::ByteAlignment;
Chris Lattner1814e812009-07-27 16:45:59 +000025 HasDotTypeDotSizeDirective = false;
26 HasSingleParameterDotFile = false;
Chris Lattner1814e812009-07-27 16:45:59 +000027 WeakRefDirective = "\t.weak\t";
Rafael Espindola04867ce2013-12-02 23:04:51 +000028 HasLinkOnceDirective = true;
Jim Grosbachdc1e36e2012-05-11 01:41:30 +000029
Chris Lattner0bfd2792010-01-23 06:53:23 +000030 // Doesn't support visibility:
Eli Friedman64a4bf12011-09-23 00:13:02 +000031 HiddenVisibilityAttr = HiddenDeclarationVisibilityAttr = MCSA_Invalid;
32 ProtectedVisibilityAttr = MCSA_Invalid;
Chris Lattner1814e812009-07-27 16:45:59 +000033
34 // Set up DWARF directives
Chris Lattner1814e812009-07-27 16:45:59 +000035 SupportsDebugInformation = true;
Matt Arsenault034ca0f2013-04-22 22:49:11 +000036 NeedsDwarfSectionOffsetDirective = true;
Daniel Sanders753e1762014-02-13 14:44:26 +000037
38 UseIntegratedAssembler = true;
Ahmed Bougacha19052872015-04-28 01:37:11 +000039
Ahmed Bougacha4a856432015-11-11 00:51:36 +000040 // At least MSVC inline-asm does AShr.
Ahmed Bougacha19052872015-04-28 01:37:11 +000041 UseLogicalShr = false;
Chris Lattner1814e812009-07-27 16:45:59 +000042}
Michael J. Spencerde3a2112011-11-29 18:00:06 +000043
David Blaikiea379b1812011-12-20 02:50:00 +000044void MCAsmInfoMicrosoft::anchor() { }
45
Michael J. Spencerde3a2112011-11-29 18:00:06 +000046MCAsmInfoMicrosoft::MCAsmInfoMicrosoft() {
Michael J. Spencerde3a2112011-11-29 18:00:06 +000047}
48
David Blaikiea379b1812011-12-20 02:50:00 +000049void MCAsmInfoGNUCOFF::anchor() { }
50
Michael J. Spencerde3a2112011-11-29 18:00:06 +000051MCAsmInfoGNUCOFF::MCAsmInfoGNUCOFF() {
52
53}