aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDevang Patel <dpatel@apple.com>2009-01-05 17:45:59 +0000
committerDevang Patel <dpatel@apple.com>2009-01-05 17:45:59 +0000
commitbbca50bc7b115d6de34d231faecffe4126e3c658 (patch)
treee97fd3873a95fb08834f2e6a6e056a2c554986e0
parent0075788e730c85424a85e7e0bfb06ba46534b8ad (diff)
downloadexternal_llvm-bbca50bc7b115d6de34d231faecffe4126e3c658.zip
external_llvm-bbca50bc7b115d6de34d231faecffe4126e3c658.tar.gz
external_llvm-bbca50bc7b115d6de34d231faecffe4126e3c658.tar.bz2
subsume ConstructPointerType()
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61711 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--lib/CodeGen/AsmPrinter/DwarfWriter.cpp10
1 files changed, 2 insertions, 8 deletions
diff --git a/lib/CodeGen/AsmPrinter/DwarfWriter.cpp b/lib/CodeGen/AsmPrinter/DwarfWriter.cpp
index 3b21ceb..13ea22c 100644
--- a/lib/CodeGen/AsmPrinter/DwarfWriter.cpp
+++ b/lib/CodeGen/AsmPrinter/DwarfWriter.cpp
@@ -1449,17 +1449,11 @@ private:
/// AddPointerType - Add a new pointer type attribute to the specified entity.
///
void AddPointerType(DIE *Entity, CompileUnit *Unit, const std::string &Name) {
- DIE *Die = ConstructPointerType(Unit, Name);
- AddDIEntry(Entity, DW_AT_type, DW_FORM_ref4, Die);
- }
-
- /// ConstructPointerType - Construct a new pointer type.
- ///
- DIE *ConstructPointerType(CompileUnit *Unit, const std::string &Name) {
DIE Buffer(DW_TAG_pointer_type);
AddUInt(&Buffer, DW_AT_byte_size, 0, TD->getPointerSize());
if (!Name.empty()) AddString(&Buffer, DW_AT_name, DW_FORM_string, Name);
- return Unit->AddDie(Buffer);
+ DIE *PointerTypeDie = Unit->AddDie(Buffer);
+ AddDIEntry(Entity, DW_AT_type, DW_FORM_ref4, PointerTypeDie);
}
/// AddType - Add a new type attribute to the specified entity.