SparcMCAsmInfo.cpp revision 235633
1224133Sdim//===-- SparcMCAsmInfo.cpp - Sparc asm properties -------------------------===//
2224133Sdim//
3224133Sdim//                     The LLVM Compiler Infrastructure
4224133Sdim//
5224133Sdim// This file is distributed under the University of Illinois Open Source
6224133Sdim// License. See LICENSE.TXT for details.
7224133Sdim//
8224133Sdim//===----------------------------------------------------------------------===//
9224133Sdim//
10224133Sdim// This file contains the declarations of the SparcMCAsmInfo properties.
11224133Sdim//
12224133Sdim//===----------------------------------------------------------------------===//
13224133Sdim
14224133Sdim#include "SparcMCAsmInfo.h"
15224133Sdim#include "llvm/ADT/Triple.h"
16224133Sdim
17224133Sdimusing namespace llvm;
18224133Sdim
19235633Sdimvoid SparcELFMCAsmInfo::anchor() { }
20235633Sdim
21224133SdimSparcELFMCAsmInfo::SparcELFMCAsmInfo(const Target &T, StringRef TT) {
22224133Sdim  IsLittleEndian = false;
23224133Sdim  Triple TheTriple(TT);
24224133Sdim  if (TheTriple.getArch() == Triple::sparcv9)
25224133Sdim    PointerSize = 8;
26224133Sdim
27224133Sdim  Data16bitsDirective = "\t.half\t";
28224133Sdim  Data32bitsDirective = "\t.word\t";
29224133Sdim  Data64bitsDirective = 0;  // .xword is only supported by V9.
30224133Sdim  ZeroDirective = "\t.skip\t";
31224133Sdim  CommentString = "!";
32224133Sdim  HasLEB128 = true;
33224133Sdim  SupportsDebugInformation = true;
34224133Sdim
35224133Sdim  SunStyleELFSectionSwitchSyntax = true;
36224133Sdim  UsesELFSectionDirectiveForBSS = true;
37224133Sdim
38224133Sdim  WeakRefDirective = "\t.weak\t";
39224133Sdim
40224133Sdim  PrivateGlobalPrefix = ".L";
41224133Sdim}
42224133Sdim
43224133Sdim
44