61 HasRVC = STI.
hasFeature(RISCV::FeatureStdExtZca);
62 HasTSO = STI.
hasFeature(RISCV::FeatureStdExtZtso);
66 bool EmitStackAlign) {
76 std::string Arch = ISAInfo->toString();
81 if (CLOpts.abi_attributes && STI.
hasFeature(RISCV::FeatureStdExtA)) {
82 unsigned AtomicABITag;
83 if (STI.
hasFeature(RISCV::FeatureStdExtZalasr))
85 else if (STI.
hasFeature(RISCV::FeatureNoTrailingSeqCstFence))
99 OS <<
"\t.option\tpush\n";
103 OS <<
"\t.option\tpop\n";
107 OS <<
"\t.option\tpic\n";
111 OS <<
"\t.option\tnopic\n";
115 OS <<
"\t.option\trvc\n";
119 OS <<
"\t.option\tnorvc\n";
123 OS <<
"\t.option\texact\n";
127 OS <<
"\t.option\tnoexact\n";
131 OS <<
"\t.option\trelax\n";
135 OS <<
"\t.option\tnorelax\n";
140 OS <<
"\t.option\tarch";
141 for (
const auto &Arg : Args) {
159 OS <<
"\t.variant_cc\t" << Symbol.getName() <<
"\n";
162void RISCVTargetAsmStreamer::emitAttribute(
unsigned Attribute,
unsigned Value) {
166void RISCVTargetAsmStreamer::emitTextAttribute(
unsigned Attribute,
171void RISCVTargetAsmStreamer::emitIntTextAttribute(
unsigned Attribute,
assert(UImm &&(UImm !=~static_cast< T >(0)) &&"Invalid immediate!")
Represent a constant reference to an array (0 or more elements consecutively in memory),...
Functions, function parameters, and return types can have attributes to indicate how they should be t...
Streaming machine code generation interface.
Generic base class for all target subtargets.
bool hasFeature(unsigned Feature) const
MCSymbol - Instances of this class represent a symbol name in the MC file, and MCSymbols are created ...
MCTargetStreamer(MCStreamer &S)
This class represents success/failure for parsing-like operations that find it important to chain tog...
void emitDirectiveOptionPIC() override
void emitDirectiveOptionExact() override
void emitDirectiveOptionArch(ArrayRef< RISCVOptionArchArg > Args) override
void emitDirectiveOptionRelax() override
RISCVTargetAsmStreamer(MCStreamer &S, formatted_raw_ostream &OS)
void emitDirectiveOptionNoRVC() override
void emitDirectiveOptionNoPIC() override
void emitDirectiveOptionPop() override
void emitDirectiveOptionNoRelax() override
void emitDirectiveOptionRVC() override
void emitDirectiveVariantCC(MCSymbol &Symbol) override
void emitDirectiveOptionNoExact() override
void emitDirectiveOptionPush() override
virtual void emitDirectiveOptionPIC()
virtual void emitDirectiveOptionNoRelax()
virtual void setArchString(StringRef Arch)
virtual void emitAttribute(unsigned Attribute, unsigned Value)
virtual void emitTextAttribute(unsigned Attribute, StringRef String)
virtual void emitDirectiveVariantCC(MCSymbol &Symbol)
void emitTargetAttributes(const MCSubtargetInfo &STI, bool EmitStackAlign)
virtual void setFlagsFromFeatures(const MCSubtargetInfo &STI)
virtual void emitIntTextAttribute(unsigned Attribute, unsigned IntValue, StringRef StringValue)
virtual void emitDirectiveOptionExact()
virtual void emitDirectiveOptionNoExact()
virtual void emitDirectiveOptionPop()
virtual void emitDirectiveOptionNoPIC()
void setTargetABI(RISCVABI::ABI ABI)
RISCVTargetStreamer(MCStreamer &S)
virtual void emitDirectiveOptionArch(ArrayRef< RISCVOptionArchArg > Args)
virtual void finishAttributeSection()
virtual void emitDirectiveOptionPush()
virtual void emitDirectiveOptionRelax()
virtual void emitDirectiveOptionNoRVC()
virtual void emitDirectiveOptionRVC()
Represent a constant reference to a string, i.e.
Twine - A lightweight data structure for efficiently representing the concatenation of temporary valu...
LLVM Value Representation.
Align getStackAlignment(ABI TargetABI)
llvm::Expected< std::unique_ptr< RISCVISAInfo > > parseFeatureBits(const MCSubtargetInfo &STI)
This is an optimization pass for GlobalISel generic memory operations.
LLVM_ABI void report_fatal_error(Error Err, bool gen_crash_diag=true)