LLVM 24.0.0git
HexagonMCAsmInfo.cpp
Go to the documentation of this file.
1//===-- HexagonMCAsmInfo.cpp - Hexagon asm properties ---------------------===//
2//
3// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4// See https://llvm.org/LICENSE.txt for license information.
5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6//
7//===----------------------------------------------------------------------===//
8//
9// This file contains the declarations of the HexagonMCAsmInfo properties.
10//
11//===----------------------------------------------------------------------===//
12
13#include "HexagonMCAsmInfo.h"
15#include "llvm/ADT/Enum.h"
16#include "llvm/MC/MCExpr.h"
17
18using namespace llvm;
19
21 {{"DTPREL"}, HexagonMCExpr::VK_DTPREL},
22 {{"GDGOT"}, HexagonMCExpr::VK_GD_GOT},
23 {{"GDPLT"}, HexagonMCExpr::VK_GD_PLT},
24 {{"GOT"}, HexagonMCExpr::VK_GOT},
25 {{"GOTREL"}, HexagonMCExpr::VK_GOTREL},
26 {{"IE"}, HexagonMCExpr::VK_IE},
27 {{"IEGOT"}, HexagonMCExpr::VK_IE_GOT},
28 {{"LDGOT"}, HexagonMCExpr::VK_LD_GOT},
29 {{"LDPLT"}, HexagonMCExpr::VK_LD_PLT},
30 {{"PCREL"}, HexagonMCExpr::VK_PCREL},
31 {{"PLT"}, HexagonMCExpr::VK_PLT},
32 {{"TPREL"}, HexagonMCExpr::VK_TPREL},
33};
35
36// Pin the vtable to this file.
37void HexagonMCAsmInfo::anchor() {}
38
42 Data16bitsDirective = "\t.half\t";
43 Data32bitsDirective = "\t.word\t";
44 Data64bitsDirective = nullptr; // .xword is only supported by V9.
45 CommentString = "//";
47
49 InlineAsmStart = "# InlineAsm Start";
50 InlineAsmEnd = "# InlineAsm End";
52 ZeroDirective = "\t.space\t";
53 AscizDirective = "\t.string\t";
54
58 UseLogicalShr = false;
59
61}
constexpr EnumStringDef< MCAsmInfo::AtSpecifierKind > AtSpecifierDefs[]
constexpr auto atSpecifiers
#define BUILD_ENUM_STRINGS(Tab)
Definition Enum.h:120
static LVOptions Options
Definition LVOptions.cpp:25
HexagonMCAsmInfo(const Triple &TT, const MCTargetOptions &Options)
MCAsmInfoELF(const MCTargetOptions &Options)
const char * Data16bitsDirective
Definition MCAsmInfo.h:243
unsigned MinInstAlignment
Every possible instruction length is a multiple of this value.
Definition MCAsmInfo.h:122
const char * Data64bitsDirective
Definition MCAsmInfo.h:245
ExceptionHandling ExceptionsType
Exception handling format for the target. Defaults to None.
Definition MCAsmInfo.h:357
const char * Data32bitsDirective
Definition MCAsmInfo.h:244
bool UsesSetToEquateSymbol
Use .set instead of = to equate a symbol to an expression.
Definition MCAsmInfo.h:148
bool UseLogicalShr
True if the integrated assembler should interpret 'a >> b' constant expressions as logical rather tha...
Definition MCAsmInfo.h:426
LCOMM::LCOMMType LCOMMDirectiveAlignmentType
Describes if the .lcomm directive for the target supports an alignment argument and how it is interpr...
Definition MCAsmInfo.h:293
const char * InlineAsmStart
If these are nonempty, they contain a directive to emit before and after an inline assembly statement...
Definition MCAsmInfo.h:169
bool UsesELFSectionDirectiveForBSS
This is true if this target uses ELF '.section' directive before the '.bss' one.
Definition MCAsmInfo.h:258
bool SupportsDebugInformation
True if target supports emission of debugging information.
Definition MCAsmInfo.h:354
const char * InlineAsmEnd
Definition MCAsmInfo.h:170
const char * ZeroDirective
This should be set to the directive used to get some number of zero (and non-zero if supported by the...
Definition MCAsmInfo.h:221
void initializeAtSpecifiers(EnumStrings< AtSpecifierKind, 1 >)
const char * AscizDirective
If not null, this allows for special handling of zero terminated strings on this target.
Definition MCAsmInfo.h:231
StringRef CommentString
This indicates the comment string used by the assembler.
Definition MCAsmInfo.h:134
Triple - Helper class for working with autoconf configuration names.
Definition Triple.h:48
This is an optimization pass for GlobalISel generic memory operations.
@ DwarfCFI
DWARF-like instruction based exceptions.
Definition CodeGen.h:55
Compile-time data representation of enum entries.
Definition Enum.h:47