mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-12 13:30:51 +00:00
Tidy up. Trailing whitespace.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@156601 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
5b6dfee28e
commit
639aa87bee
@ -12,7 +12,7 @@
|
||||
#include "llvm/Support/DataTypes.h"
|
||||
|
||||
namespace llvm {
|
||||
|
||||
|
||||
#define EDIS_MAX_OPERANDS 13
|
||||
#define EDIS_MAX_SYNTAXES 2
|
||||
|
||||
@ -23,7 +23,7 @@ struct EDInstInfo {
|
||||
uint8_t operandFlags[EDIS_MAX_OPERANDS];
|
||||
const signed char operandOrders[EDIS_MAX_SYNTAXES][EDIS_MAX_OPERANDS];
|
||||
};
|
||||
|
||||
|
||||
} // namespace llvm
|
||||
|
||||
#endif
|
||||
|
@ -13,13 +13,13 @@
|
||||
#include "llvm-c/Disassembler.h"
|
||||
|
||||
namespace llvm {
|
||||
|
||||
|
||||
class MCInst;
|
||||
class MCSubtargetInfo;
|
||||
class MemoryObject;
|
||||
class raw_ostream;
|
||||
class MCContext;
|
||||
|
||||
|
||||
struct EDInstInfo;
|
||||
|
||||
/// MCDisassembler - Superclass for all disassemblers. Consumes a memory region
|
||||
@ -58,12 +58,12 @@ public:
|
||||
MCDisassembler(const MCSubtargetInfo &STI) : GetOpInfo(0), SymbolLookUp(0),
|
||||
DisInfo(0), Ctx(0),
|
||||
STI(STI), CommentStream(0) {}
|
||||
|
||||
|
||||
virtual ~MCDisassembler();
|
||||
|
||||
|
||||
/// getInstruction - Returns the disassembly of a single instruction.
|
||||
///
|
||||
/// @param instr - An MCInst to populate with the contents of the
|
||||
/// @param instr - An MCInst to populate with the contents of the
|
||||
/// instruction.
|
||||
/// @param size - A value to populate with the size of the instruction, or
|
||||
/// the number of bytes consumed while attempting to decode
|
||||
@ -74,7 +74,7 @@ public:
|
||||
/// @param vStream - The stream to print warnings and diagnostic messages on.
|
||||
/// @param cStream - The stream to print comments and annotations on.
|
||||
/// @return - MCDisassembler::Success if the instruction is valid,
|
||||
/// MCDisassembler::SoftFail if the instruction was
|
||||
/// MCDisassembler::SoftFail if the instruction was
|
||||
/// disassemblable but invalid,
|
||||
/// MCDisassembler::Fail if the instruction was invalid.
|
||||
virtual DecodeStatus getInstruction(MCInst& instr,
|
||||
|
@ -194,7 +194,7 @@ public:
|
||||
VK_Mips_GPOFF_LO,
|
||||
VK_Mips_GOT_DISP,
|
||||
VK_Mips_GOT_PAGE,
|
||||
VK_Mips_GOT_OFST
|
||||
VK_Mips_GOT_OFST
|
||||
};
|
||||
|
||||
private:
|
||||
|
@ -18,7 +18,7 @@ struct MCFixupKindInfo {
|
||||
/// Is this fixup kind PCrelative? This is used by the assembler backend to
|
||||
/// evaluate fixup values in a target independent manner when possible.
|
||||
FKF_IsPCRel = (1 << 0),
|
||||
|
||||
|
||||
/// Should this fixup kind force a 4-byte aligned effective PC value?
|
||||
FKF_IsAlignedDownTo32Bits = (1 << 1)
|
||||
};
|
||||
|
@ -22,17 +22,17 @@ namespace llvm {
|
||||
class StringRef;
|
||||
class Triple;
|
||||
|
||||
class MCObjectFileInfo {
|
||||
class MCObjectFileInfo {
|
||||
protected:
|
||||
/// CommDirectiveSupportsAlignment - True if .comm supports alignment. This
|
||||
/// is a hack for as long as we support 10.4 Tiger, whose assembler doesn't
|
||||
/// support alignment on comm.
|
||||
bool CommDirectiveSupportsAlignment;
|
||||
|
||||
|
||||
/// SupportsWeakEmptyEHFrame - True if target object file supports a
|
||||
/// weak_definition of constant 0 for an omitted EH frame.
|
||||
bool SupportsWeakOmittedEHFrame;
|
||||
|
||||
|
||||
/// IsFunctionEHFrameSymbolPrivate - This flag is set to true if the
|
||||
/// "EH_frame" symbol for EH information should be an assembler temporary (aka
|
||||
/// private linkage, aka an L or .L label) or false if it should be a normal
|
||||
@ -53,20 +53,20 @@ protected:
|
||||
/// TextSection - Section directive for standard text.
|
||||
///
|
||||
const MCSection *TextSection;
|
||||
|
||||
|
||||
/// DataSection - Section directive for standard data.
|
||||
///
|
||||
const MCSection *DataSection;
|
||||
|
||||
|
||||
/// BSSSection - Section that is default initialized to zero.
|
||||
const MCSection *BSSSection;
|
||||
|
||||
|
||||
/// ReadOnlySection - Section that is readonly and can contain arbitrary
|
||||
/// initialized data. Targets are not required to have a readonly section.
|
||||
/// If they don't, various bits of code will fall back to using the data
|
||||
/// section for constants.
|
||||
const MCSection *ReadOnlySection;
|
||||
|
||||
|
||||
/// StaticCtorSection - This section contains the static constructor pointer
|
||||
/// list.
|
||||
const MCSection *StaticCtorSection;
|
||||
@ -74,7 +74,7 @@ protected:
|
||||
/// StaticDtorSection - This section contains the static destructor pointer
|
||||
/// list.
|
||||
const MCSection *StaticDtorSection;
|
||||
|
||||
|
||||
/// LSDASection - If exception handling is supported by the target, this is
|
||||
/// the section the Language Specific Data Area information is emitted to.
|
||||
const MCSection *LSDASection;
|
||||
@ -109,7 +109,7 @@ protected:
|
||||
// Extra TLS Variable Data section. If the target needs to put additional
|
||||
// information for a TLS variable, it'll go here.
|
||||
const MCSection *TLSExtraDataSection;
|
||||
|
||||
|
||||
/// TLSDataSection - Section directive for Thread Local data.
|
||||
/// ELF, MachO and COFF.
|
||||
const MCSection *TLSDataSection; // Defaults to ".tdata".
|
||||
@ -141,11 +141,11 @@ protected:
|
||||
/// Contains the source code name of the variable, visibility and a pointer
|
||||
/// to the initial value (.tdata or .tbss).
|
||||
const MCSection *TLSTLVSection; // Defaults to ".tlv".
|
||||
|
||||
|
||||
/// TLSThreadInitSection - Section for thread local data initialization
|
||||
/// functions.
|
||||
const MCSection *TLSThreadInitSection; // Defaults to ".thread_init_func".
|
||||
|
||||
|
||||
const MCSection *CStringSection;
|
||||
const MCSection *UStringSection;
|
||||
const MCSection *TextCoalSection;
|
||||
@ -169,7 +169,7 @@ protected:
|
||||
public:
|
||||
void InitMCObjectFileInfo(StringRef TT, Reloc::Model RM, CodeModel::Model CM,
|
||||
MCContext &ctx);
|
||||
|
||||
|
||||
bool isFunctionEHFrameSymbolPrivate() const {
|
||||
return IsFunctionEHFrameSymbolPrivate;
|
||||
}
|
||||
|
@ -14,72 +14,72 @@
|
||||
|
||||
namespace llvm {
|
||||
class Target;
|
||||
|
||||
|
||||
/// MCTargetAsmLexer - Generic interface to target specific assembly lexers.
|
||||
class MCTargetAsmLexer {
|
||||
/// The current token
|
||||
AsmToken CurTok;
|
||||
|
||||
|
||||
/// The location and description of the current error
|
||||
SMLoc ErrLoc;
|
||||
std::string Err;
|
||||
|
||||
|
||||
MCTargetAsmLexer(const MCTargetAsmLexer &); // DO NOT IMPLEMENT
|
||||
void operator=(const MCTargetAsmLexer &); // DO NOT IMPLEMENT
|
||||
protected: // Can only create subclasses.
|
||||
MCTargetAsmLexer(const Target &);
|
||||
|
||||
|
||||
virtual AsmToken LexToken() = 0;
|
||||
|
||||
|
||||
void SetError(const SMLoc &errLoc, const std::string &err) {
|
||||
ErrLoc = errLoc;
|
||||
Err = err;
|
||||
}
|
||||
|
||||
|
||||
/// TheTarget - The Target that this machine was created for.
|
||||
const Target &TheTarget;
|
||||
MCAsmLexer *Lexer;
|
||||
|
||||
|
||||
public:
|
||||
virtual ~MCTargetAsmLexer();
|
||||
|
||||
|
||||
const Target &getTarget() const { return TheTarget; }
|
||||
|
||||
|
||||
/// InstallLexer - Set the lexer to get tokens from lower-level lexer \arg L.
|
||||
void InstallLexer(MCAsmLexer &L) {
|
||||
Lexer = &L;
|
||||
}
|
||||
|
||||
|
||||
MCAsmLexer *getLexer() {
|
||||
return Lexer;
|
||||
}
|
||||
|
||||
|
||||
/// Lex - Consume the next token from the input stream and return it.
|
||||
const AsmToken &Lex() {
|
||||
return CurTok = LexToken();
|
||||
}
|
||||
|
||||
|
||||
/// getTok - Get the current (last) lexed token.
|
||||
const AsmToken &getTok() {
|
||||
return CurTok;
|
||||
}
|
||||
|
||||
|
||||
/// getErrLoc - Get the current error location
|
||||
const SMLoc &getErrLoc() {
|
||||
return ErrLoc;
|
||||
}
|
||||
|
||||
|
||||
/// getErr - Get the current error string
|
||||
const std::string &getErr() {
|
||||
return Err;
|
||||
}
|
||||
|
||||
|
||||
/// getKind - Get the kind of current token.
|
||||
AsmToken::TokenKind getKind() const { return CurTok.getKind(); }
|
||||
|
||||
|
||||
/// is - Check if the current token has kind \arg K.
|
||||
bool is(AsmToken::TokenKind K) const { return CurTok.is(K); }
|
||||
|
||||
|
||||
/// isNot - Check if the current token has kind \arg K.
|
||||
bool isNot(AsmToken::TokenKind K) const { return CurTok.isNot(K); }
|
||||
};
|
||||
|
@ -11,7 +11,7 @@
|
||||
// from a base address plus an offset. Register indirection can be specified by
|
||||
// using an offset of zero.
|
||||
//
|
||||
// The MachineMove class is used to represent abstract move operations in the
|
||||
// The MachineMove class is used to represent abstract move operations in the
|
||||
// prolog/epilog of a compiled function. A collection of these objects can be
|
||||
// used by a debug consumer to track the location of values when unwinding stack
|
||||
// frames.
|
||||
@ -23,7 +23,7 @@
|
||||
|
||||
namespace llvm {
|
||||
class MCSymbol;
|
||||
|
||||
|
||||
class MachineLocation {
|
||||
private:
|
||||
bool IsRegister; // True if location is a register.
|
||||
@ -46,7 +46,7 @@ public:
|
||||
return IsRegister == Other.IsRegister && Register == Other.Register &&
|
||||
Offset == Other.Offset;
|
||||
}
|
||||
|
||||
|
||||
// Accessors
|
||||
bool isReg() const { return IsRegister; }
|
||||
unsigned getReg() const { return Register; }
|
||||
@ -77,7 +77,7 @@ private:
|
||||
/// Label - Symbol for post-instruction address when result of move takes
|
||||
/// effect.
|
||||
MCSymbol *Label;
|
||||
|
||||
|
||||
// Move to & from location.
|
||||
MachineLocation Destination, Source;
|
||||
public:
|
||||
@ -86,7 +86,7 @@ public:
|
||||
MachineMove(MCSymbol *label, const MachineLocation &D,
|
||||
const MachineLocation &S)
|
||||
: Label(label), Destination(D), Source(S) {}
|
||||
|
||||
|
||||
// Accessors
|
||||
MCSymbol *getLabel() const { return Label; }
|
||||
const MachineLocation &getDestination() const { return Destination; }
|
||||
|
@ -25,7 +25,7 @@
|
||||
namespace llvm {
|
||||
class raw_ostream;
|
||||
class StringRef;
|
||||
|
||||
|
||||
//===----------------------------------------------------------------------===//
|
||||
///
|
||||
/// SubtargetFeatureKV - Used to provide key value pairs for feature and
|
||||
@ -36,13 +36,13 @@ struct SubtargetFeatureKV {
|
||||
const char *Desc; // Help descriptor
|
||||
uint64_t Value; // K-V integer value
|
||||
uint64_t Implies; // K-V bit mask
|
||||
|
||||
|
||||
// Compare routine for std binary search
|
||||
bool operator<(const SubtargetFeatureKV &S) const {
|
||||
return strcmp(Key, S.Key) < 0;
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
//===----------------------------------------------------------------------===//
|
||||
///
|
||||
/// SubtargetInfoKV - Used to provide key value pairs for CPU and arbitrary
|
||||
@ -51,16 +51,16 @@ struct SubtargetFeatureKV {
|
||||
struct SubtargetInfoKV {
|
||||
const char *Key; // K-V key string
|
||||
void *Value; // K-V pointer value
|
||||
|
||||
|
||||
// Compare routine for std binary search
|
||||
bool operator<(const SubtargetInfoKV &S) const {
|
||||
return strcmp(Key, S.Key) < 0;
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
//===----------------------------------------------------------------------===//
|
||||
///
|
||||
/// SubtargetFeatures - Manages the enabling and disabling of subtarget
|
||||
/// SubtargetFeatures - Manages the enabling and disabling of subtarget
|
||||
/// specific features. Features are encoded as a string of the form
|
||||
/// "cpu,+attr1,+attr2,-attr3,...,+attrN"
|
||||
/// A comma separates each feature from the next (all lowercase.)
|
||||
@ -81,27 +81,27 @@ public:
|
||||
|
||||
/// Adding Features.
|
||||
void AddFeature(const StringRef String, bool IsEnabled = true);
|
||||
|
||||
|
||||
/// ToggleFeature - Toggle a feature and returns the newly updated feature
|
||||
/// bits.
|
||||
uint64_t ToggleFeature(uint64_t Bits, const StringRef String,
|
||||
const SubtargetFeatureKV *FeatureTable,
|
||||
size_t FeatureTableSize);
|
||||
|
||||
|
||||
/// Get feature bits of a CPU.
|
||||
uint64_t getFeatureBits(const StringRef CPU,
|
||||
const SubtargetFeatureKV *CPUTable,
|
||||
size_t CPUTableSize,
|
||||
const SubtargetFeatureKV *FeatureTable,
|
||||
size_t FeatureTableSize);
|
||||
|
||||
|
||||
/// Get scheduling itinerary of a CPU.
|
||||
void *getItinerary(const StringRef CPU,
|
||||
const SubtargetInfoKV *Table, size_t TableSize);
|
||||
|
||||
|
||||
/// Print feature string.
|
||||
void print(raw_ostream &OS) const;
|
||||
|
||||
|
||||
// Dump feature info.
|
||||
void dump() const;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user