From c5dac4df2ea91969604a12d418954ab026603c99 Mon Sep 17 00:00:00 2001 From: Rafael Espindola Date: Thu, 28 Apr 2011 16:09:09 +0000 Subject: Add a getExprForPersonalitySymbol method to MCAsmInfo. Use it when converting the symbol passed to .cfi_personality into bytes is the file. llvm-svn: 130400 --- llvm/lib/MC/MCAsmInfo.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'llvm/lib/MC/MCAsmInfo.cpp') diff --git a/llvm/lib/MC/MCAsmInfo.cpp b/llvm/lib/MC/MCAsmInfo.cpp index 116c007a451..873802ae980 100644 --- a/llvm/lib/MC/MCAsmInfo.cpp +++ b/llvm/lib/MC/MCAsmInfo.cpp @@ -13,6 +13,8 @@ //===----------------------------------------------------------------------===// #include "llvm/MC/MCAsmInfo.h" +#include "llvm/MC/MCExpr.h" +#include "llvm/MC/MCStreamer.h" #include "llvm/Support/DataTypes.h" #include #include @@ -106,3 +108,9 @@ unsigned MCAsmInfo::getSLEB128Size(int Value) { } while (IsMore); return Size; } + +const MCExpr * +MCAsmInfo::getExprForPersonalitySymbol(const MCSymbol *Sym, + MCStreamer &Streamer) const { + return MCSymbolRefExpr::Create(Sym, Streamer.getContext()); +} -- cgit v1.2.3