mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-15 21:24:00 +00:00
get MMI out of the label uniquing business, just go to MCContext
to get unique assembler temporary labels. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@98489 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -22,7 +22,6 @@
|
||||
#include "llvm/Target/TargetInstrInfo.h"
|
||||
#include "llvm/Target/TargetMachine.h"
|
||||
#include "llvm/Target/TargetOptions.h"
|
||||
#include "llvm/MC/MCAsmInfo.h"
|
||||
#include "llvm/MC/MCSymbol.h"
|
||||
#include "llvm/Support/Dwarf.h"
|
||||
#include "llvm/Support/ErrorHandling.h"
|
||||
@ -41,7 +40,7 @@ MachineModuleInfoImpl::~MachineModuleInfoImpl() {}
|
||||
|
||||
MachineModuleInfo::MachineModuleInfo(const MCAsmInfo &MAI)
|
||||
: ImmutablePass(&ID), Context(MAI),
|
||||
ObjFileMMI(0), NextLabelIDToReturn(1),
|
||||
ObjFileMMI(0),
|
||||
CurCallSite(0), CallsEHReturn(0), CallsUnwindInit(0), DbgInfoAvailable(false){
|
||||
// Always emit some info, by default "no personality" info.
|
||||
Personalities.push_back(NULL);
|
||||
@ -70,12 +69,6 @@ bool MachineModuleInfo::doFinalization() {
|
||||
return false;
|
||||
}
|
||||
|
||||
/// getLabelSym - Turn a label ID into a symbol.
|
||||
MCSymbol *MachineModuleInfo::getLabelSym(unsigned ID) {
|
||||
return Context.GetOrCreateTemporarySymbol
|
||||
(Twine(Context.getAsmInfo().getPrivateGlobalPrefix()) + "label" +Twine(ID));
|
||||
}
|
||||
|
||||
/// EndFunction - Discard function meta information.
|
||||
///
|
||||
void MachineModuleInfo::EndFunction() {
|
||||
@ -140,7 +133,7 @@ void MachineModuleInfo::addInvoke(MachineBasicBlock *LandingPad,
|
||||
/// addLandingPad - Provide the label of a try LandingPad block.
|
||||
///
|
||||
MCSymbol *MachineModuleInfo::addLandingPad(MachineBasicBlock *LandingPad) {
|
||||
MCSymbol *LandingPadLabel = getLabelSym(NextLabelID());
|
||||
MCSymbol *LandingPadLabel = Context.CreateTempSymbol();
|
||||
LandingPadInfo &LP = getOrCreateLandingPadInfo(LandingPad);
|
||||
LP.LandingPadLabel = LandingPadLabel;
|
||||
return LandingPadLabel;
|
||||
|
Reference in New Issue
Block a user