1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-25 20:23:11 +01:00

Forward isFunctionEHFrameSymbolPrivate. If it is false, produce the foo.eh

symbols.

llvm-svn: 130375
This commit is contained in:
Rafael Espindola 2011-04-28 02:46:42 +00:00
parent 900ceb725b
commit d2ef63ca76
2 changed files with 11 additions and 0 deletions

View File

@ -62,6 +62,10 @@ public:
return TLOF->getFDEEncoding();
}
bool isFunctionEHFrameSymbolPrivate() const {
return TLOF->isFunctionEHFrameSymbolPrivate();
}
unsigned getDwarfRARegNum(bool isEH) const {
return TRI->getDwarfRegNum(TRI->getRARegister(), isEH);
}

View File

@ -17,6 +17,7 @@
#include "llvm/MC/MCContext.h"
#include "llvm/MC/MCObjectWriter.h"
#include "llvm/ADT/SmallString.h"
#include "llvm/ADT/Twine.h"
#include "llvm/Support/Debug.h"
#include "llvm/Support/ErrorHandling.h"
#include "llvm/Support/raw_ostream.h"
@ -713,6 +714,12 @@ MCSymbol *FrameEmitterImpl::EmitFDE(MCStreamer &streamer,
MCSymbol *fdeEnd = context.CreateTempSymbol();
const TargetAsmInfo &asmInfo = context.getTargetAsmInfo();
if (!asmInfo.isFunctionEHFrameSymbolPrivate()) {
Twine EHName = frame.Function->getName() + Twine(".eh");
MCSymbol *EHSym = context.GetOrCreateSymbol(EHName);
streamer.EmitLabel(EHSym);
}
// Length
const MCExpr *Length = MakeStartMinusEndExpr(streamer, *fdeStart, *fdeEnd, 0);
streamer.EmitAbsValue(Length, 4);