LLVM 24.0.0git
MipsTargetObjectFile.h
Go to the documentation of this file.
1//===-- llvm/Target/MipsTargetObjectFile.h - Mips Object 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#ifndef LLVM_LIB_TARGET_MIPS_MIPSTARGETOBJECTFILE_H
10#define LLVM_LIB_TARGET_MIPS_MIPSTARGETOBJECTFILE_H
11
13
14namespace llvm {
16 MCSection *SmallDataSection;
17 MCSection *SmallBSSSection;
18 const bool UseSmallSection;
19
20 bool IsGlobalInSmallSection(const GlobalObject *GO, SectionKind Kind) const;
21 bool IsGlobalInSmallSectionImpl(const GlobalObject *GO) const;
22
23public:
24 explicit MipsTargetObjectFile(bool UseSmallSection)
25 : UseSmallSection(UseSmallSection) {}
26
27 void Initialize(MCContext &Ctx, const TargetMachine &TM) override;
28
29 /// Return true if this global address should be placed into small data/bss
30 /// section.
31 bool IsGlobalInSmallSection(const GlobalObject *GO) const;
32
34 const TargetMachine &TM) const override;
35
36 /// Return true if this constant should be placed into small data section.
37 bool IsConstantInSmallSection(const DataLayout &DL, const Constant *CN,
38 const Function *F) const;
39
41 const Constant *C, Align &Alignment,
42 const Function *F) const override;
43 /// Describe a TLS variable address within debug info.
44 const MCExpr *getDebugThreadLocalSymbol(const MCSymbol *Sym) const override;
45};
46} // end namespace llvm
47
48#endif
MachineBasicBlock MachineBasicBlock::iterator DebugLoc DL
static GCRegistry::Add< ShadowStackGC > C("shadow-stack", "Very portable GC for uncooperative code generators")
#define F(x, y, z)
Definition MD5.cpp:54
This is an important base class in LLVM.
Definition Constant.h:43
A parsed version of the target data layout string in and methods for querying it.
Definition DataLayout.h:64
Context object for machine code objects.
Definition MCContext.h:83
Base class for the full range of assembler expressions which are needed for parsing.
Definition MCExpr.h:34
Instances of this class represent a uniqued identifier for a section in the current translation unit.
Definition MCSection.h:580
MCSymbol - Instances of this class represent a symbol name in the MC file, and MCSymbols are created ...
Definition MCSymbol.h:42
bool IsConstantInSmallSection(const DataLayout &DL, const Constant *CN, const Function *F) const
Return true if this constant should be placed into small data section.
MCSection * SelectSectionForGlobal(const GlobalObject *GO, SectionKind Kind, const TargetMachine &TM) const override
const MCExpr * getDebugThreadLocalSymbol(const MCSymbol *Sym) const override
Describe a TLS variable address within debug info.
MipsTargetObjectFile(bool UseSmallSection)
MCSection * getSectionForConstant(const DataLayout &DL, SectionKind Kind, const Constant *C, Align &Alignment, const Function *F) const override
Return true if this constant should be placed into small data section.
void Initialize(MCContext &Ctx, const TargetMachine &TM) override
This method must be called before any actual lowering is done.
SectionKind - This is a simple POD value that classifies the properties of a section.
Definition SectionKind.h:22
Primary interface to the complete machine description for the target machine.
This is an optimization pass for GlobalISel generic memory operations.
This struct is a compact representation of a valid (non-zero power of two) alignment.
Definition Alignment.h:39