LLVM 19.0.0git
MCSectionSPIRV.h
Go to the documentation of this file.
1//===- MCSectionSPIRV.h - SPIR-V Machine Code Sections ----------*- 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 declares the MCSectionSPIRV class.
10//
11//===----------------------------------------------------------------------===//
12
13#ifndef LLVM_MC_MCSECTIONSPIRV_H
14#define LLVM_MC_MCSECTIONSPIRV_H
15
16#include "llvm/MC/MCSection.h"
17#include "llvm/MC/SectionKind.h"
18
19namespace llvm {
20
21class MCSymbol;
22
23class MCSectionSPIRV final : public MCSection {
24 friend class MCContext;
25
27 : MCSection(SV_SPIRV, "", K, Begin) {}
28 // TODO: Add StringRef Name to MCSectionSPIRV.
29
30public:
31 ~MCSectionSPIRV() = default;
32 void printSwitchToSection(const MCAsmInfo &MAI, const Triple &T,
34 const MCExpr *Subsection) const override {}
35 bool useCodeAlign() const override { return false; }
36 bool isVirtualSection() const override { return false; }
37};
38
39} // end namespace llvm
40
41#endif // LLVM_MC_MCSECTIONSPIRV_H
raw_pwrite_stream & OS
This class is intended to be used as a base class for asm properties and features specific to the tar...
Definition: MCAsmInfo.h:56
Context object for machine code objects.
Definition: MCContext.h:76
Base class for the full range of assembler expressions which are needed for parsing.
Definition: MCExpr.h:35
bool isVirtualSection() const override
Check whether this section is "virtual", that is has no actual object file contents.
void printSwitchToSection(const MCAsmInfo &MAI, const Triple &T, raw_ostream &OS, const MCExpr *Subsection) const override
~MCSectionSPIRV()=default
bool useCodeAlign() const override
Return true if a .align directive should use "optimized nops" to fill instead of 0s.
Instances of this class represent a uniqued identifier for a section in the current translation unit.
Definition: MCSection.h:39
MCSymbol - Instances of this class represent a symbol name in the MC file, and MCSymbols are created ...
Definition: MCSymbol.h:40
SectionKind - This is a simple POD value that classifies the properties of a section.
Definition: SectionKind.h:22
Triple - Helper class for working with autoconf configuration names.
Definition: Triple.h:44
This class implements an extremely fast bulk output stream that can only output to a stream.
Definition: raw_ostream.h:52
This is an optimization pass for GlobalISel generic memory operations.
Definition: AddressRanges.h:18