mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-01-06 04:31:08 +00:00
7b06b7357a
suffix (e.g. .xdata$myfunc). The suffix part isn't implemented yet, but I'll get to it in the next patch. Fix up all callers of the affected functions. Make them pass said suffix to the function. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@132205 91177308-0d34-0410-b5e6-96231b3b80d8
105 lines
2.7 KiB
C++
105 lines
2.7 KiB
C++
//===-- llvm/Target/TargetAsmInfo.h -----------------------------*- C++ -*-===//
|
|
//
|
|
// The LLVM Compiler Infrastructure
|
|
//
|
|
// This file is distributed under the University of Illinois Open Source
|
|
// License. See LICENSE.TXT for details.
|
|
//
|
|
//===----------------------------------------------------------------------===//
|
|
//
|
|
// Interface to provide the information necessary for producing assembly files.
|
|
//
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
#ifndef LLVM_TARGET_TARGETASMINFO_H
|
|
#define LLVM_TARGET_TARGETASMINFO_H
|
|
|
|
#include "llvm/CodeGen/MachineLocation.h"
|
|
#include "llvm/Target/TargetLoweringObjectFile.h"
|
|
#include "llvm/Target/TargetFrameLowering.h"
|
|
#include "llvm/Target/TargetRegisterInfo.h"
|
|
|
|
namespace llvm {
|
|
class MCSection;
|
|
class MCContext;
|
|
class MachineFunction;
|
|
class TargetMachine;
|
|
class TargetLoweringObjectFile;
|
|
|
|
class TargetAsmInfo {
|
|
unsigned PointerSize;
|
|
bool IsLittleEndian;
|
|
TargetFrameLowering::StackDirection StackDir;
|
|
const TargetRegisterInfo *TRI;
|
|
std::vector<MachineMove> InitialFrameState;
|
|
const TargetLoweringObjectFile *TLOF;
|
|
|
|
public:
|
|
explicit TargetAsmInfo(const TargetMachine &TM);
|
|
|
|
/// getPointerSize - Get the pointer size in bytes.
|
|
unsigned getPointerSize() const {
|
|
return PointerSize;
|
|
}
|
|
|
|
/// islittleendian - True if the target is little endian.
|
|
bool isLittleEndian() const {
|
|
return IsLittleEndian;
|
|
}
|
|
|
|
TargetFrameLowering::StackDirection getStackGrowthDirection() const {
|
|
return StackDir;
|
|
}
|
|
|
|
const MCSection *getDwarfLineSection() const {
|
|
return TLOF->getDwarfLineSection();
|
|
}
|
|
|
|
const MCSection *getEHFrameSection() const {
|
|
return TLOF->getEHFrameSection();
|
|
}
|
|
|
|
const MCSection *getDwarfFrameSection() const {
|
|
return TLOF->getDwarfFrameSection();
|
|
}
|
|
|
|
const MCSection *getWin64EHFuncTableSection(StringRef Suffix) const {
|
|
return TLOF->getWin64EHFuncTableSection(Suffix);
|
|
}
|
|
|
|
const MCSection *getWin64EHTableSection(StringRef Suffix) const {
|
|
return TLOF->getWin64EHTableSection(Suffix);
|
|
}
|
|
|
|
unsigned getFDEEncoding(bool CFI) const {
|
|
return TLOF->getFDEEncoding(CFI);
|
|
}
|
|
|
|
bool isFunctionEHFrameSymbolPrivate() const {
|
|
return TLOF->isFunctionEHFrameSymbolPrivate();
|
|
}
|
|
|
|
const unsigned *getCalleeSavedRegs(MachineFunction *MF = 0) const {
|
|
return TRI->getCalleeSavedRegs(MF);
|
|
}
|
|
|
|
unsigned getDwarfRARegNum(bool isEH) const {
|
|
return TRI->getDwarfRegNum(TRI->getRARegister(), isEH);
|
|
}
|
|
|
|
const std::vector<MachineMove> &getInitialFrameState() const {
|
|
return InitialFrameState;
|
|
}
|
|
|
|
int getDwarfRegNum(unsigned RegNum, bool isEH) const {
|
|
return TRI->getDwarfRegNum(RegNum, isEH);
|
|
}
|
|
|
|
int getSEHRegNum(unsigned RegNum) const {
|
|
return TRI->getSEHRegNum(RegNum);
|
|
}
|
|
};
|
|
|
|
}
|
|
#endif
|