LLVM 23.0.0git
RISCVMCAsmInfo.h
Go to the documentation of this file.
1//===-- RISCVMCAsmInfo.h - RISC-V Asm Info ---------------------*- C++ -*--===//
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 declaration of the RISCVMCAsmInfo class.
10//
11//===----------------------------------------------------------------------===//
12
13#ifndef LLVM_LIB_TARGET_RISCV_MCTARGETDESC_RISCVMCASMINFO_H
14#define LLVM_LIB_TARGET_RISCV_MCTARGETDESC_RISCVMCASMINFO_H
15
18#include "llvm/MC/MCFixup.h"
19
20namespace llvm {
21class Triple;
22
24 void anchor() override;
25
26public:
27 explicit RISCVMCAsmInfo(const Triple &TargetTriple,
29
30 const MCExpr *getExprForFDESymbol(const MCSymbol *Sym, unsigned Encoding,
31 MCStreamer &Streamer) const override;
33 const MCSpecifierExpr &Expr) const override;
34};
35
36namespace RISCV {
38// Specifiers mapping to relocation types below FirstTargetFixupKind are
39// encoded literally, with these exceptions:
40enum {
42 // Specifiers mapping to distinct relocation types.
49 // Vendor-specific relocation types might conflict across vendors.
50 // Refer to them using Specifier constants.
52};
53
56} // namespace RISCV
57
59public:
62 const MCSpecifierExpr &Expr) const override;
63};
64
65} // namespace llvm
66
67#endif
static LVOptions Options
Definition LVOptions.cpp:25
static const char * name
MCAsmInfoDarwin(const MCTargetOptions &Options)
MCAsmInfoELF(const MCTargetOptions &Options)
Base class for the full range of assembler expressions which are needed for parsing.
Definition MCExpr.h:34
Extension point for target-specific MCExpr subclasses with a relocation specifier,...
Definition MCExpr.h:495
Streaming machine code generation interface.
Definition MCStreamer.h:222
MCSymbol - Instances of this class represent a symbol name in the MC file, and MCSymbols are created ...
Definition MCSymbol.h:42
RISCVMCAsmInfoDarwin(const MCTargetOptions &Options)
void printSpecifierExpr(raw_ostream &OS, const MCSpecifierExpr &Expr) const override
void printSpecifierExpr(raw_ostream &OS, const MCSpecifierExpr &Expr) const override
const MCExpr * getExprForFDESymbol(const MCSymbol *Sym, unsigned Encoding, MCStreamer &Streamer) const override
RISCVMCAsmInfo(const Triple &TargetTriple, const MCTargetOptions &Options)
StringRef - Represent a constant reference to a string, i.e.
Definition StringRef.h:55
Triple - Helper class for working with autoconf configuration names.
Definition Triple.h:47
This class implements an extremely fast bulk output stream that can only output to a stream.
Definition raw_ostream.h:53
Specifier parseSpecifierName(StringRef name)
StringRef getSpecifierName(Specifier Kind)
uint16_t Specifier
This is an optimization pass for GlobalISel generic memory operations.
@ FirstTargetFixupKind
Definition MCFixup.h:44